From 77f2a82d2796d633aecaed877268ec248d6d8635 Mon Sep 17 00:00:00 2001 From: Maysun J Faisal Date: Mon, 10 Jul 2023 14:37:33 -0400 Subject: [PATCH 1/6] Update port from 8081 to 8080 Signed-off-by: Maysun J Faisal --- README.md | 2 +- deploy.yaml | 8 ++++---- devfile.yaml | 6 +++--- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index ffb581df..ed586fa2 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Creating an application with a Spring Boot code sample -**Note:** The Spring Boot code sample uses the **8081** HTTP port. +**Note:** The Spring Boot 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 3c536360..54e1769a 100644 --- a/deploy.yaml +++ b/deploy.yaml @@ -17,7 +17,7 @@ spec: image: java-springboot-image:latest ports: - name: http - containerPort: 8081 + containerPort: 8080 protocol: TCP resources: requests: @@ -30,9 +30,9 @@ metadata: name: my-java-springboot-svc spec: ports: - - name: http-8081 - port: 8081 + - name: http-8080 + port: 8080 protocol: TCP - targetPort: 8081 + targetPort: 8080 selector: app: java-springboot-app \ No newline at end of file diff --git a/devfile.yaml b/devfile.yaml index 18fd490e..e6a6a3a0 100644 --- a/devfile.yaml +++ b/devfile.yaml @@ -30,12 +30,12 @@ components: deployment/replicas: 1 deployment/cpuRequest: 10m deployment/memoryRequest: 180Mi - 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 From dd1ab743752cc6f9142fcc05a9f0dd46ad398351 Mon Sep 17 00:00:00 2001 From: Maysun J Faisal Date: Tue, 11 Jul 2023 17:28:11 -0400 Subject: [PATCH 2/6] Update dockerfile port Signed-off-by: Maysun J Faisal --- docker/Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index abad1840..f586562e 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -7,7 +7,7 @@ # # Then run the container using: # -# docker run -i --rm -p 8081:8081 springboot/sample-demo +# docker run -i --rm -p 8080:8080 springboot/sample-demo #### FROM registry.access.redhat.com/ubi8/openjdk-17:1.15-1.1682053058 AS builder @@ -25,6 +25,6 @@ RUN mv /home/jboss/target/$(cat .env-id)-$(cat .env-version).jar /home/jboss/tar FROM registry.access.redhat.com/ubi8/openjdk-17-runtime:1.15-1.1682053056 COPY --from=builder /home/jboss/target/export-run-artifact.jar /deployments/export-run-artifact.jar -EXPOSE 8081 -ENTRYPOINT ["/opt/jboss/container/java/run/run-java.sh", "--server.port=8081"] +EXPOSE 8080 +ENTRYPOINT ["/opt/jboss/container/java/run/run-java.sh", "--server.port=8080"] From 8fc311d3f1792d5a4554d5dae90221aa22abfeb9 Mon Sep 17 00:00:00 2001 From: thepetk Date: Mon, 9 Oct 2023 16:58:57 +0100 Subject: [PATCH 3/6] Update devfile version Signed-off-by: thepetk --- devfile.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devfile.yaml b/devfile.yaml index e6a6a3a0..39324c95 100644 --- a/devfile.yaml +++ b/devfile.yaml @@ -1,7 +1,7 @@ schemaVersion: 2.2.0 metadata: name: java-springboot - version: 1.2.1 + version: 1.2.2 attributes: alpha.dockerimage-port: 8081 displayName: Spring Boot® From eab2053d63c5b5aea20395c6a731e172d7d06c6c Mon Sep 17 00:00:00 2001 From: thepetk Date: Tue, 17 Oct 2023 12:44:46 +0100 Subject: [PATCH 4/6] Fix dockerfile Signed-off-by: thepetk --- docker/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index c158f1e4..8c89cb22 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -25,7 +25,7 @@ RUN grep version target/maven-archiver/pom.properties | cut -d '=' -f2 >.env-ver RUN grep artifactId target/maven-archiver/pom.properties | cut -d '=' -f2 >.env-id RUN mv target/$(cat .env-id)-$(cat .env-version).jar target/export-run-artifact.jar -FROM registry.access.redhat.com/ubi8/openjdk-17-runtime:1.15-1.1682053056` +FROM registry.access.redhat.com/ubi8/openjdk-17-runtime:1.15-1.1682053056 COPY --from=builder /home/jboss/target/export-run-artifact.jar /deployments/export-run-artifact.jar EXPOSE 8080 From f2711a849fbc4a304cadc50403c9ba53587334ee Mon Sep 17 00:00:00 2001 From: thepetk Date: Wed, 18 Oct 2023 14:58:24 +0100 Subject: [PATCH 5/6] Update version of sample Signed-off-by: thepetk --- README.md | 2 +- devfile.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index ed586fa2..a1922892 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Creating an application with a Spring Boot code sample -**Note:** The Spring Boot code sample uses the **8080** HTTP port. +**Note:** The Spring Boot code sample version `2.0.0` 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/devfile.yaml b/devfile.yaml index 39324c95..23a0e23c 100644 --- a/devfile.yaml +++ b/devfile.yaml @@ -1,7 +1,7 @@ schemaVersion: 2.2.0 metadata: name: java-springboot - version: 1.2.2 + version: 2.0.0 attributes: alpha.dockerimage-port: 8081 displayName: Spring Boot® From 8c8359446d2bbe2c5f409077393b2f5b16ebf152 Mon Sep 17 00:00:00 2001 From: Theofanis Petkos Date: Mon, 23 Oct 2023 13:22:00 +0100 Subject: [PATCH 6/6] Update README.md Signed-off-by: thepetk --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index a1922892..ff3e2935 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Creating an application with a Spring Boot code sample -**Note:** The Spring Boot code sample version `2.0.0` uses the **8080** HTTP port. +**Note:** The Spring Boot code sample version 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: