From 17523dcca574b2038cf35018b498ef1256f48583 Mon Sep 17 00:00:00 2001 From: Matthias Linhuber Date: Mon, 6 May 2024 17:57:22 +0200 Subject: [PATCH] Add docker build phase --- Dockerfile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index c3ad1bb..e1957c4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,9 @@ -FROM openjdk:17 +FROM docker.io/library/eclipse-temurin:17-jdk as builder +COPY . . +RUN ./gradlew hermes:bootJar + +FROM docker.io/library/eclipse-temurin:17-jdk WORKDIR /. -COPY hermes/build/libs/hermes-0.0.1-SNAPSHOT.jar ./app.jar +COPY --from=builder /hermes/build/libs/hermes-0.0.1-SNAPSHOT.jar app.jar ENTRYPOINT ["java", "-jar", "./app.jar"]