Cannot connect Fusionauth service to Google Cloud SQL instance

4/7/2020

I'm trying to set up fusionauth to run on GKE (kubernetes) and connect to a Cloud SQL Mysql instance for the DB. I have been able to successfully set up a GCE instance but when I try to migrate to GKE I am getting the following error in Maintenance mode:

Unable to create the ordinary user using the username and password you provided. Perhaps the username is invalid or uses a reserved word. The error from the database was [Operation CREATE USER failed for 'fusionauth'@'%']. 

Steps I've taken:

  • I've verified that the fusionauth user does exist, I've even deleted the user and found that in maintenance mode the user does get created (although without privileges of any kind).

  • I've started with a fresh cloud sql instance and updated the user/password and connection url on the pods but still no joy.

  • I've verified that I can reach the Cloud SQL instance from a pod on the same subnet as the fusionauth container.

Furthermore, when I provide root username/password and connection url for silent configuration mode, that also fails citing the root user/password or search url as being either incorrect or having insufficient privileges. However Considering the same root user is used on the GCE instance and everything works so that can't be it. And I've verified I can reach the search container with the provided url so that rules that out.

And I've searched google and the fusionauth site for answers and/or a tutorial or something on how to do this exactly. But I've come up empty handed. Based on FA's sever layout examples it looks like it should be do-able but everything I've seen on Fusionauth in GKE uses a PVC for the DB, not Cloud SQL.

So my question is simple, what am I missing? Or what am I doing wrong?

-- DNate
fusionauth
google-cloud-sql
google-kubernetes-engine
kubernetes

0 Answers