cptactionhank/docker-atlassian-bitbucket

Possibility to specify truststore for certificates via environment parameter (e.g. X_TRUSTSTORE_PATH)

Closed this issue · 2 comments

Hello,

as we are using an HTTPS connection between JIRA, Confluence and Bitbucket it would be nice to have a environment variable that contains a path to a truststore containing the certificates for the different servers.

Currently, we install bitbucket, jira and confluence server, link a data container for each containing the keystore and afterwards do an exec into the running server to change the /opt/atlassian/bitbucket/bin/setenv.sh file to add the line -Djavax.net.ssl.trustStore=. Otherwise, the application linking will fail.

Do you mind adding something like X_TRUSTSTORE_PATH to your entrypoint.sh file that automatically modifies the setenv.sh file, so this manual step is no longer necessary?

Thank you for considering this,

Best regards,

Bard

PS: the same applies to your Jira and Confluence images too. If you want me to open a separate issue there, drop me a line.

It should not be necessary, have you tried supplying the JVM argument in the CATALINA_OPTS environment variable where you eg. also could set Xms, Xms, and plugin timeout? Something like the following should be sufficient:

docker create --restart=no --name "jira-container" \
    --publish "8080:8080" \
    --env "CATALINA_OPTS=-Djavax.net.ssl.trustStore=." \
    cptactionhank/atlassian-bitbucket:latest

Ahh very cool, thank you. I did not think about this. I will try this :-)

Btw. I tried the latest bitbucket image and it failed for me as you are starting catalina directly and don't use the supplied start-bitbucket.sh. This unfortunately starts an elastic search server too, which is missing when you start catalina directly. I know this should be a separate issue, but I'm lazy right now.