'Cant connect to Cloud SQL from Cloud Composer using Public IP
I'm trying to connect my instance of Google Composer to Google cloud Postgres. I am trying to do this via the Public IP. The DAG error is saying I cant connect to the server. The DAG is using a postgres operator.
I then have a connection configured in my composer instance. This has the public ip of my Cloud SQL Postgres server.
I think the error is around not allowing the cloud composer ip into the firewall for the Cloud SQL server. Am I doing this the wrong way? Should I be using a different operator? Ive been stuck on this for a few days now and exhausted my options from google.
Any help would be greatly appreciated!
Thanks
Solution 1:[1]
You have to update the authorized network on Cloud SQL to allow the Composer public IP. Be sure to only grant the public IP.
In addition, keep in mind that, out of the box, the Cloud SQL traffic is not encrypted and if you use private IP with CLoud SQL proxy, it's strongly recommended to add SSL on the Cloud SQL database
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | guillaume blaquiere |


