gitlab-runner-gateway/Dockerfile

29 lines
615 B
Docker

FROM oracle/graalvm-ce:20.1.0-java11 as builder
ADD .mvn/ /build/.mvn
ADD mvnw /build
WORKDIR /build
# Install GraalVM Native Image
RUN gu install native-image; \
./mvnw --version \
native-image --version
COPY pom.xml /build
RUN ./mvnw clean dependency:go-offline
ADD src/ /build/src/
ADD Makefile /build
# download dependencies and compile into layer
RUN ./mvnw -Pgraal compile
# generate graalvm image into another layer
RUN ./mvnw -Pgraal package
#FROM debian:buster
FROM scratch
COPY --from=builder /build/target/wikiProject /wikiproject
COPY --from=builder /tmp /tmp
ENTRYPOINT ["/wikiproject"]