Skip to content

Commit 91f017b

Browse files
committed
library-api: dockerfile fix
1 parent 0a798a7 commit 91f017b

File tree

1 file changed

+6
-22
lines changed

1 file changed

+6
-22
lines changed
Lines changed: 6 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,12 @@
1-
# Use Kogito builder image with Java 17
2-
FROM quay.io/kiegroup/kogito-swf-builder:1.44.1 AS builder
3-
4-
WORKDIR $KOGITO_HOME
5-
6-
# Copy the Maven configuration and source code
7-
COPY ./pom.xml ./
8-
COPY ./src ./src
9-
10-
# Set JAVA_HOME and PATH for Java 17
11-
ENV JAVA_HOME=/usr/lib/jvm/java-17
12-
ENV PATH=$JAVA_HOME/bin:$PATH
13-
14-
# Build the application
15-
RUN $MAVEN_HOME/bin/mvn clean package -Dmaven.compiler.release=17
16-
171
# Use Kogito runtime image with Java 17
182
FROM quay.io/kiegroup/kogito-runtime-jvm:1.44.1
193

20-
ENV RUNTIME_TYPE quarkus
4+
ENV RUNTIME_TYPE=quarkus
215
ENV JAVA_HOME=/usr/lib/jvm/java-17
226
ENV PATH=$JAVA_HOME/bin:$PATH
237

24-
# Copy the built application
25-
COPY --from=builder /home/kogito/target/quarkus-app/lib/ $KOGITO_HOME/bin/lib/
26-
COPY --from=builder /home/kogito/target/quarkus-app/*.jar $KOGITO_HOME/bin
27-
COPY --from=builder /home/kogito/target/quarkus-app/app/ $KOGITO_HOME/bin/app/
28-
COPY --from=builder /home/kogito/target/quarkus-app/quarkus/ $KOGITO_HOME/bin/quarkus/
8+
# Copy the pre-built application (built by GitHub Actions before Docker)
9+
COPY target/quarkus-app/lib/ $KOGITO_HOME/bin/lib/
10+
COPY target/quarkus-app/*.jar $KOGITO_HOME/bin/
11+
COPY target/quarkus-app/app/ $KOGITO_HOME/bin/app/
12+
COPY target/quarkus-app/quarkus/ $KOGITO_HOME/bin/quarkus/

0 commit comments

Comments
 (0)