Skip to content

Commit 67a09f8

Browse files
authored
Merge pull request #46 from SpringBootCourses/#45
#45 Improve Dockerfile
2 parents 705694d + 5fb8af1 commit 67a09f8

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 -DskipTests
5+
RUN mvn package -DskipTests
56

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

0 commit comments

Comments
 (0)