Skip to content

Commit 161246d

Browse files
committed
add file to enable buildah to work
- fixes "empty" copy issue
1 parent 981e8b3 commit 161246d

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/main/docker/Dockerfile.jvm.staged

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ RUN grep artifactId /build/target/maven-archiver/pom.properties | cut -d '=' -f2
3434

3535
# mv the uber jar in case the quarkus property quarkus.package.type=uber-jar is set
3636
RUN mv /build/target/$(cat .env-id)-$(cat .env-version)*.jar /build/target/quarkus-app-tmp/
37-
37+
RUN echo "copyhack" > /build/target/copyhack
3838
FROM registry.access.redhat.com/ubi8/ubi-minimal:8.7-1085
3939

4040
ARG JAVA_PACKAGE=java-17-openjdk-devel
@@ -57,12 +57,12 @@ RUN microdnf install curl ca-certificates ${JAVA_PACKAGE} \
5757
# Configure the JAVA_OPTIONS, you can add -XshowSettings:vm to also display the heap size.
5858
ENV JAVA_OPTIONS="-Dquarkus.http.host=0.0.0.0 -Dquarkus.http.port=8081 -Djava.util.logging.manager=org.jboss.logmanager.LogManager"
5959
# We make four distinct layers so if there are application changes the library layers can be re-used
60-
COPY --from=0 --chown=1001 /build/target/quarkus-app-tmp/*.jar /deployments/export-run-artifact.jar
61-
COPY --from=0 --chown=1001 /build/target/*quarkus-app/*lib/ /deployments/lib/
60+
COPY --from=0 --chown=1001 /build/target/copyhack /build/target/quarkus-app-tmp/*.jar /deployments/export-run-artifact.jar
61+
COPY --from=0 --chown=1001 /build/target/copyhack /build/target/*quarkus-app/*lib/ /deployments/lib/
6262
# Overwrite the uber jar if package type is normal
63-
COPY --from=0 --chown=1001 /build/target/*quarkus-app/*.jar /deployments/export-run-artifact.jar
64-
COPY --from=0 --chown=1001 /build/target/*quarkus-app/*app/ /deployments/app/
65-
COPY --from=0 --chown=1001 /build/target/*quarkus-app/*quarkus/ /deployments/quarkus/
63+
COPY --from=0 --chown=1001 /build/target/copyhack /build/target/*quarkus-app/*.jar /deployments/export-run-artifact.jar
64+
COPY --from=0 --chown=1001 /build/target/copyhack /build/target/*quarkus-app/*app/ /deployments/app/
65+
COPY --from=0 --chown=1001 /build/target/copyhack /build/target/*quarkus-app/*quarkus/ /deployments/quarkus/
6666

6767
EXPOSE 8081
6868
USER 1001

0 commit comments

Comments
 (0)