-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add docker files for standalone spring application
- Loading branch information
Showing
6 changed files
with
78 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Uncomment to enable CDS | ||
#FROM eclipse-temurin:8u352-b08-jre-jammy as builder | ||
FROM ubuntu/chiselled-jre:8_edge | ||
#COPY --from=builder /opt/java/openjdk/lib/classlist /usr/lib/jvm/java-8-openjdk-amd64/jre/lib | ||
#COPY --from=builder /bin/sh /bin/sh | ||
#USER root | ||
#RUN /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java -Xshare:dump | ||
#USER app | ||
ADD acmeair-java-2.0.0-SNAPSHOT.jar / | ||
#CMD [ "-Xshare:on", "-jar", "/acmeair-java-2.0.0-SNAPSHOT.jar" ] | ||
CMD [ "-jar", "/acmeair-java-2.0.0-SNAPSHOT.jar" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
FROM eclipse-temurin:8u352-b08-jre-jammy | ||
|
||
ADD acmeair-java-2.0.0-SNAPSHOT.jar / | ||
# uncomment to enabled CDS | ||
#RUN java -Xshare:dump | ||
#CMD [ "java", "-Xshare:on", "-jar", "/acmeair-java-2.0.0-SNAPSHOT.jar" ] | ||
CMD [ "java", "-jar", "/acmeair-java-2.0.0-SNAPSHOT.jar" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
version: '3' | ||
services: | ||
acmeair-db: | ||
container_name: acmeair-db | ||
image: mongo | ||
ports: | ||
- "27017:27017" | ||
networks: | ||
- acme | ||
|
||
tomcat: | ||
container_name: acmeair-standalone-temurin | ||
image: acmeair-standalone-temurin | ||
networks: | ||
- acme | ||
ports: | ||
- "9080:8080" | ||
- "9443:8443" | ||
- "7777:7777" | ||
environment: | ||
- MONGO_HOST=acmeair-db | ||
tmpfs: | ||
- /tmp | ||
|
||
networks: | ||
acme: | ||
driver: bridge |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
version: '3' | ||
services: | ||
acmeair-db: | ||
container_name: acmeair-db | ||
image: mongo | ||
ports: | ||
- "27017:27017" | ||
networks: | ||
- acme | ||
|
||
tomcat: | ||
container_name: acmeair-standalone-temurin | ||
image: acmeair-standalone-temurin | ||
networks: | ||
- acme | ||
ports: | ||
- "9080:8080" | ||
- "9443:8443" | ||
- "7777:7777" | ||
environment: | ||
- MONGO_HOST=acmeair-db | ||
tmpfs: | ||
- /tmp | ||
|
||
networks: | ||
acme: | ||
driver: bridge |