A simple fix for using ca-certificates to update Java cacerts store for container.
Due to the update-ca-certificates will output the Java cacerts store to /etc/ssl/certs/java/cacerts which the pre-built image not aware of the changes. So by removing the ${JAVA_HOME}/lib/security/cacerts and create a symbolic link from /etc/ssl/certs/java/cacerts to ${JAVA_HOME}/lib/security/cacerts will resolve the issue.
FROM eclipse-temurin:17-jre-alpine