Skip to content

Commit 8d3f111

Browse files
authored
Merge pull request #40 from SpringBootCourses/#39
#39 Improve Dockerfile
2 parents d80970f + 01047d7 commit 8d3f111

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Dockerfile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
FROM maven:3.8.5-openjdk-17 AS build
2+
COPY pom.xml .
3+
RUN mvn dependency:go-offline
24
COPY /src /src
3-
COPY pom.xml /
4-
RUN mvn -f /pom.xml clean package
5+
RUN mvn clean package -DskipTests
56

67
FROM openjdk:17-jdk-slim
78
COPY --from=build /target/*.jar application.jar

0 commit comments

Comments
 (0)