Connecting my GKE cluster to our local db on premise

6/21/2019

Please how do I connect my Google Cloud kubernetes cluster to my database on premise . I know about the anthos option but I don't think we need to be that extensive . We want to run our services online but these services need to connect to our mysql db on premise. What is the most cost effective and efficient way to handle this?.

-- I.Tyger
gke-networking
google-kubernetes-engine

1 Answer

6/25/2019

My recommendation is to use a Cloud VPN tunnel1 to connect to on-premise. If you are using multiple projects you can connect them all to a host project by using a Shared VPC. This way you can also benefit your on-premise side from the Private Google Access2. The other aproach is by using Cloud Interconnect3. This establish a more secure and efficient connection between your on-premise to your GCP platform, but it will also cost more. After this you will only need to make sure you have the particular firewall rule to expose the mysql service through the tunnel.


-- Lozano
Source: StackOverflow