Turns out I just need to add this to the Docker file, where ldap.cer is the certificate chain for my self-signed certificate.
COPY ldap.cer $JAVA_HOME/jre/lib/security RUN \ cd $JAVA_HOME/jre/lib/security \ && keytool -keystore cacerts -storepass changeit -noprompt -trustcacerts -importcert -alias ldapcert -file ldap.cer
source share