mezzotre/Dockerfile

19 lines
424 B
Docker

ARG DEBUG_BUILD
FROM eclipse-temurin:17-jdk as builder
WORKDIR /build
COPY . /build
RUN ./mvnw package -B -DskipTests=true \
-Dmaven.test.skip=true \
-Dmaven.site.skip=true \
-Dmaven.javadoc.skip=true | grep -Ev '(Downloading|Downloaded)'
FROM gcr.io/distroless/java17:${DEBUG_BUILD}nonroot
COPY --from=builder /build/target/mezzotre.jar /opt/mezzotre.jar
ENTRYPOINT ["java", "-jar", "/opt/mezzotre.jar"]