Skip to content

Commit ac57ff1

Browse files
Specify default libraries path to LD_LIBRARY_PATH and JVM flag java.library.path.
1 parent b2aa3b5 commit ac57ff1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/main/docker/Dockerfile.jvm

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,8 @@ COPY --from=builder /usr/local/lib/libsodium.so* /usr/local/lib/
9999
COPY --from=builder /usr/local/include/sodium/ /usr/local/include/sodium/
100100
RUN ldconfig
101101

102+
ENV LD_LIBRARY_PATH=/usr/local/lib
103+
102104
# We make four distinct layers so if there are application changes the library layers can be re-used
103105
COPY --chown=185 build/quarkus-app/lib/ /deployments/lib/
104106
COPY --chown=185 build/quarkus-app/*.jar /deployments/
@@ -107,7 +109,7 @@ COPY --chown=185 build/quarkus-app/quarkus/ /deployments/quarkus/
107109

108110
EXPOSE 8080
109111
USER 185
110-
ENV JAVA_OPTS_APPEND="-Dquarkus.http.host=0.0.0.0 -Djava.util.logging.manager=org.jboss.logmanager.LogManager"
112+
ENV JAVA_OPTS_APPEND="-Djava.library.path=/usr/local/lib -Dquarkus.http.host=0.0.0.0 -Djava.util.logging.manager=org.jboss.logmanager.LogManager"
111113
ENV JAVA_APP_JAR="/deployments/quarkus-run.jar"
112114

113115
ENTRYPOINT [ "/opt/jboss/container/java/run/run-java.sh" ]

0 commit comments

Comments
 (0)