Keytool:
keytool -delete -noprompt -alias ${cert.alias} -keystore ${keystore.file} -storepass ${keystore.pass}
keytool -delete -noprompt -alias ${cert.alias} -keystore ${keystore.file} -storepass ${keystore.pass}
keytool -keystore cacerts -import -alias ${cert.alias} -file ca.pem
Set certificate path in Java:
-Djavax.net.ssl.trustStore=/Library/Java/JavaVirtualMachines/jdk1.7.0_75.jdk/Contents/Home/jre/lib/security/cacerts