[opencms-dev] OpenCms 11 setup on Docker containers with separate mysql 8 container - allowPublicKeyRetrieval
Sandrine Prousteau
s.prousteau at eurelis.com
Sun Jul 14 14:26:42 CEST 2019
Hi all !
I'm trying to install install OpenCms 11 on custom Docker containers, and I
face this issue :
System requirements tested successfully.
Setup-Bean initialized successfully.
Exception: java.sql.SQLNonTransientConnectionException: Public Key
Retrieval is not allowed
at
com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:110)
at
com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97)
at
com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122)
at
com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:835)
at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:455)
at
com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:240)
at
com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:199)
at
java.sql/java.sql.DriverManager.getConnection(DriverManager.java:677)
at
java.sql/java.sql.DriverManager.getConnection(DriverManager.java:228)
at org.opencms.setup.CmsSetupDb.setConnection(CmsSetupDb.java:518)
at org.opencms.setup.CmsSetupDb.setConnection(CmsSetupDb.java:488)
at org.opencms.setup.CmsAutoSetup.setupDB(CmsAutoSetup.java:280)
at org.opencms.setup.CmsAutoSetup.run(CmsAutoSetup.java:212)
at org.opencms.setup.CmsAutoSetup.main(CmsAutoSetup.java:135)
An error occurred during the setup process with the following error message:
DB Connection test faild.
Please have a look into the opencms log file for detailed information.
Deleting no longer used files
This error occurs on the command :
java -classpath
"${OPENCMS_HOME}/WEB-INF/lib/*:${OPENCMS_HOME}/WEB-INF/classes:${TOMCAT_LIB}/*"
org.opencms.setup.CmsAutoSetup -path ${CONFIG_FILE}
in 20_check_install.sh
After some search, I found that I should add this
?allowPublicKeyRetrieval=true&useSSL=false
to the db.pool.default.jdbcUrl.params in the opencms.properties
But these properties are managed at the install by OpenCms setup classes,
and reading the classes I didn't found how I can customize it.
Is there a solution / workaround?
My config is :
Docker desktop (community) on Windows 10 pro :
* Engine 18.09.2
* Compose 1.23.2
A Dockerfile based on "alpine:latest", containing Alkacon Dockerfile ENV
and resources/,
A docker-compose file, creating a mysql:8.0 container, and my container
running my image, on which I run a script to install openjdk11, tomcat9,
apache2.4, and finally OpenCms using Alkacon scripts.
Thanks for your help !
Sandrine P.
https://www.eurelis.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20190714/9fc89532/attachment.htm>
More information about the opencms-dev
mailing list