-
The quarkus docs cover username/password mode: https://quarkus.io/guides/deploying-to-google-cloud#using-cloud-sql-with-a-jdbc-driver but we're using this way of connecting w/ special SSL certs: https://cloud.google.com/sql/docs/mysql/connect-admin-ip#connect-ssl |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
FYI, you use this: Now hitting this cryptic error:
using this in application.properties:
|
Beta Was this translation helpful? Give feedback.
-
FYI, these two lines were not required: %stg.quarkus.datasource.jdbc.additional-jdbc-properties.cloudSqlInstance=myproj-stg:us-central1:myproj-regional-primary Also had to set db-kind to mysql: Because it's using the serverPublicKey, it's just a regular mysql connection but SSL encrypted so no need for the socket connector... |
Beta Was this translation helpful? Give feedback.
FYI, these two lines were not required:
%stg.quarkus.datasource.jdbc.additional-jdbc-properties.cloudSqlInstance=myproj-stg:us-central1:myproj-regional-primary
%stg.quarkus.datasource.jdbc.additional-jdbc-properties.socketFactory=com.google.cloud.sql.mysql.SocketFactory
Also had to set db-kind to mysql:
%stg.quarkus.datasource.db-kind=mysql
And also the URL needed our internal IP address to reach it:
%stg.quarkus.datasource.jdbc.url=jdbc:mysql://<internal_ip_to_cloudsql>/myproj_db_stg
Because it's using the serverPublicKey, it's just a regular mysql connection but SSL encrypted so no need for the socket connector...