From 4d95733cdfe63b33c33e47b31e0434650d144c49 Mon Sep 17 00:00:00 2001 From: Maysun J Faisal Date: Mon, 10 Jul 2023 14:40:10 -0400 Subject: [PATCH] Update port from 8081 to 8080 Signed-off-by: Maysun J Faisal --- README.md | 2 +- deploy.yaml | 8 ++++---- devfile.yaml | 6 +++--- docker/Dockerfile | 6 +++--- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index e96053f1e..c25ef55a0 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Creating an application with a Python code sample -**Note:** The Python code sample uses the **8081** HTTP port. +**Note:** The Python code sample uses the **8080** HTTP port. Before you begin creating an application with this `devfile` code sample, it's helpful to understand the relationship between the `devfile` and `Dockerfile` and how they contribute to your build. You can find these files at the following URLs: diff --git a/deploy.yaml b/deploy.yaml index a8a92259d..ae69b9a5d 100644 --- a/deploy.yaml +++ b/deploy.yaml @@ -17,7 +17,7 @@ spec: image: python-image:latest ports: - name: http - containerPort: 8081 + containerPort: 8080 protocol: TCP resources: requests: @@ -30,9 +30,9 @@ metadata: name: my-python spec: ports: - - name: http-8081 - port: 8081 + - name: http-8080 + port: 8080 protocol: TCP - targetPort: 8081 + targetPort: 8080 selector: app: python-app diff --git a/devfile.yaml b/devfile.yaml index b4572435c..eb00d0b09 100644 --- a/devfile.yaml +++ b/devfile.yaml @@ -33,12 +33,12 @@ components: deployment/replicas: 1 deployment/cpuRequest: 10m deployment/memoryRequest: 50Mi - deployment/container-port: 8081 + deployment/container-port: 8080 kubernetes: uri: deploy.yaml endpoints: - - name: http-8081 - targetPort: 8081 + - name: http-8080 + targetPort: 8080 path: / commands: - id: build-image diff --git a/docker/Dockerfile b/docker/Dockerfile index 89eca3285..274925853 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,8 +1,8 @@ FROM registry.access.redhat.com/ubi9/python-39:1-117.1684741281 -# By default, listen on port 8081 -EXPOSE 8081/tcp -ENV FLASK_PORT=8081 +# By default, listen on port 8080 +EXPOSE 8080/tcp +ENV FLASK_PORT=8080 # Set the working directory in the container WORKDIR /projects