Questions tagged [cloud-sql-proxy]
243 questions
17
votes
2 answers
Connecting to multiple CloudSQL instances using Cloud sql proxy?
I'm attempting to use the cloud sql proxy to connect to 2 different cloud sql instances...
In the docs I found a line about Use -instances parameter. For multiple instances, use a comma-separated list. but not sure how to make that look.…

glesage
- 955
- 2
- 16
- 31
10
votes
3 answers
Start CloudSQL Proxy on Python Dataflow / Apache Beam
I am currently working on a ETL Dataflow job (using the Apache Beam Python SDK) which queries data from CloudSQL (with psycopg2 and a custom ParDo) and writes it to BigQuery. My goal is to create a Dataflow template which I can start from a…

Thomas Schmidt
- 305
- 2
- 11
9
votes
1 answer
no connection pool with primary found
I am using Rails and am experiencing a connection pool error very randomly and it does not target any single endpoint specifically. I can hit endpoints about 70% of the time without getting this error. The database is PostgreSQL running on Google…

Pablo Marti Cordero
- 944
- 2
- 9
- 23
8
votes
1 answer
zsh command not found cloud_sql_proxy
I'm trying to connect to the Google Cloud SQL through local proxy. When I try to use cloud_sql_proxy in the Terminal on Mac, it says zsh command not found cloud_sql_proxy

JIANG
- 1,687
- 2
- 19
- 36
8
votes
1 answer
How to use environment variable in kubernetes container command?
I am trying to deploy cloudsql proxy as sidecar contaier like this:
- name: cloudsql-proxy
image: gcr.io/cloudsql-docker/gce-proxy:1.11
command: ["/cloud_sql_proxy",
…

Bunyk
- 7,635
- 8
- 47
- 79
8
votes
3 answers
Multiple K8S containers connecting to Google Cloud SQL through proxy
I would like to connect my Kubernetes cluster to Google Cloud SQL.
I have at least 10 different deployed pods which presently connect to MySQL [docker image deployed to k8s] using a JDBC url + username/password.
It it possible to use a single…

Hylton Peimer
- 548
- 5
- 16
7
votes
2 answers
Connecting to Cloud SQL from Cloud Run via cloud-sql-proxy with IAM login enabled
I would like to connect to a Cloud SQL instance from Cloud Run, using a service account. The connection used to be created within the VPC and we would just provide a connection string with a user and a password to our PostgreSQL client. But now we…

kluu
- 2,848
- 3
- 15
- 35
7
votes
3 answers
How to create CloudSQL Proxy credentials as secrets on GKE
I've followed the steps at https://cloud.google.com/sql/docs/mysql/connect-kubernetes-engine to set up MySQL user accounts and service accounts. I've downloaded the JSON file containing my credentials.
My issue is that in the code I copied from the…

shalvah
- 881
- 10
- 21
6
votes
2 answers
CloudSQL Proxy on GKE : Service vs Sidecar
Does anyone know the pros and cons for installing the CloudSQL-Proxy (that allows us to connect securely to CloudSQL) on a Kubernetes cluster as a service as opposed to making it a sidecar against the application container?
I know that it is mostly…

Sayon Roy Choudhury
- 117
- 2
- 8
6
votes
3 answers
Connecting to Cloud SQL using an IAM user
I'm failing to test the ability to use an IAM user in Google Cloud's PostgreSQL offering.
Here's my thinking process:
I've set respective flag on my PostgreSQL instance on Google Cloud:
$ gcloud sql instances describe [MY_DB_INSTANCE] --format json…

oldhomemovie
- 14,621
- 13
- 64
- 99
6
votes
3 answers
GUI to view data in Google Cloud SQL
We are using a PostgreSQL database within Cloud SQL. We are using a private IP address and are accessing our database in our pods with the Cloud SQL proxy.
We are now looking for a way to quickly and easily access data in those databases. As far as…

Harold L. Brown
- 8,423
- 11
- 57
- 109
6
votes
1 answer
Google Cloud SQL proxy with Docker throws connection refused
I am trying to connect an application (docker container) to a Google Cloud SQL database using a cloudsql-proxy docker container. Therefore, I've created a docker-compose file with the following cloudsql-proxy container:
(XXX replaced with my cloud…

pbeck
- 107
- 1
- 6
6
votes
3 answers
Connection refused to running Google Cloud SQL instance via proxy or from App Engine
I'm very new to Google Cloud and running applications in general. I currently have a Django app running in a Docker container on Google Flexible App Engine that connects to a Google Cloud SQL (PostgreSQL) instance in the same project. The latest…

Arasithil
- 61
- 2
- 4
5
votes
1 answer
How to Connect to Cloud SQL using Python?
Connecting to Cloud SQL using Python is not always straightforward.
Depending on the context, sometimes you have to connect to a Unix domain socket, allow-list IP addresses for TCP connections, run the Cloud SQL Auth proxy locally. Making these…

Jack Wotherspoon
- 1,131
- 3
- 13
5
votes
2 answers
GCP Composer v1.18.6 and 2.0.10 incompatible with CloudSqlProxyRunner
In my Composer Airflow DAGs, I have been using the CloudSqlProxyRunner to connect to my Cloud SQL instance.
However, after updating Google Cloud Composer from v1.18.4 to 1.18.6, my DAG started to encounter a strange error:
[2022-04-22, 23:20:18 UTC]…

anna_hope
- 335
- 3
- 9