Skip to content

Commit

Permalink
Merge pull request #240 from camunda/108-add-support-for-self-signed-…
Browse files Browse the repository at this point in the history
…ssl-certificates

chore: moved java execution to start.sh
  • Loading branch information
igpetrov authored Jan 30, 2023
2 parents a7bfc47 + 2c43b69 commit 53a2bec
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
6 changes: 4 additions & 2 deletions bundle/mvn/default-bundle/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,7 @@ RUN mkdir /opt/app
# Download connectors from maven central
COPY target/*-with-dependencies.jar /opt/app/

# Using entry point to allow downstream images to add JVM arguments using CMD
ENTRYPOINT ["java", "-cp", "/opt/app/*", "io.camunda.connector.runtime.ConnectorRuntimeApplication"]
COPY start.sh /start.sh
RUN chmod +x start.sh

ENTRYPOINT ["/start.sh"]
19 changes: 19 additions & 0 deletions bundle/mvn/default-bundle/start.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/bin/bash

JAVA_OPTS="${JAVA_OPTS}"

# Explicitly set trust store location
if [[ -n "${JAVAX_NET_SSL_TRUSTSTORE}" ]]; then
JAVA_OPTS="${JAVA_OPTS} -Djavax.net.ssl.trustStore=${JAVAX_NET_SSL_TRUSTSTORE}"
fi

# Explicitly set trust store password
if [[ -n "${JAVAX_NET_SSL_TRUSTSTOREPASSWORD}" ]]; then
JAVA_OPTS="${JAVA_OPTS} -Djavax.net.ssl.trustStorePassword=${JAVAX_NET_SSL_TRUSTSTOREPASSWORD}"
fi

if [[ -n ${DEBUG_JVM_PRINT_JAVA_OPTS} ]]; then
echo "Applied JVM options: $JAVA_OPTS"
fi

exec java ${JAVA_OPTS} -cp /opt/app/* io.camunda.connector.runtime.ConnectorRuntimeApplication

0 comments on commit 53a2bec

Please sign in to comment.