2020-03-12 13:02:26 +03:00
|
|
|
FROM maven:3.6.3-jdk-11 AS build
|
2020-03-05 21:23:28 +03:00
|
|
|
COPY pom.xml .
|
|
|
|
RUN mvn --batch-mode dependency:resolve
|
|
|
|
COPY . .
|
|
|
|
RUN mvn --batch-mode package
|
|
|
|
RUN cp target/*jar target/app.jar
|
|
|
|
|
2020-03-12 13:02:26 +03:00
|
|
|
FROM openjdk:11-jre
|
2020-03-05 21:23:28 +03:00
|
|
|
EXPOSE 8080
|
|
|
|
VOLUME /tmp
|
|
|
|
COPY --from=build target/app.jar app.jar
|
|
|
|
ENTRYPOINT ["java","-Djava.security.egd=file:/dev/./urandom","-jar","/app.jar"]
|