6c148d897b
Change-Id: Ic3153c8e8a9b78df02a5a8f590ed20dc78d85b95
16 lines
385 B
Docker
16 lines
385 B
Docker
#
|
|
# Build stage
|
|
#
|
|
FROM docker.io/library/maven:3.9.2-eclipse-temurin-17 AS build
|
|
COPY src /home/app/src
|
|
COPY pom.xml /home/app
|
|
RUN mvn -f /home/app/pom.xml clean package
|
|
|
|
#
|
|
# Package stage
|
|
#
|
|
FROM docker.io/library/eclipse-temurin:17-jre
|
|
COPY --from=build /home/app/target/demo-0.0.1-SNAPSHOT.jar /usr/local/lib/demo.jar
|
|
EXPOSE 8080
|
|
ENTRYPOINT ["java","-jar","/usr/local/lib/demo.jar"]
|