File tree Expand file tree Collapse file tree
docker-modules/docker-spring-boot Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99
1010 <parent >
1111 <groupId >com.baeldung</groupId >
12- <artifactId >parent-boot-2 </artifactId >
12+ <artifactId >parent-boot-3 </artifactId >
1313 <version >0.0.1-SNAPSHOT</version >
14- <relativePath >../../parent-boot-2 </relativePath >
14+ <relativePath >../../parent-boot-3 </relativePath >
1515 </parent >
1616
1717 <dependencies >
Original file line number Diff line number Diff line change 22#
33# docker build -f src/main/docker/Dockerfile .
44
5- FROM adoptopenjdk:11-jre-hotspot as builder
5+ FROM openjdk:17-jdk-alpine as builder
66ARG JAR_FILE=target/*.jar
77COPY ${JAR_FILE} application.jar
88RUN java -Djarmode=layertools -jar application.jar extract
99
10- FROM adoptopenjdk:11-jre-hotspot
10+ FROM openjdk:17-jdk-alpine
1111COPY --from=builder dependencies/ ./
1212COPY --from=builder spring-boot-loader/ ./
1313COPY --from=builder internal-dependencies/ ./
Original file line number Diff line number Diff line change 66# To run with profiles:
77# docker run -e "SPRING_PROFILES_ACTIVE=test1,test2,test3" docker-with-spring-profile:latest
88
9- FROM openjdk:11
9+ FROM openjdk:17-jdk-alpine
1010COPY target/*.jar app.jar
1111ENTRYPOINT ["java" , "-jar" , "/app.jar" ]
You can’t perform that action at this time.
0 commit comments