Is there and outbound firewall policy? If yes, you'd have to make sure it allows connections to port 3307 per this public doc.
On Thursday, March 4, 2021 at 10:53:01 AM UTC-5 rcdh wrote:
Hi there,recently started evaluating gcp for tooling and have a question regarding the cloud-proxy that starts automatically.I dont seem to be able to connect to it in the documented manner on 127.0.0.1:3307Anyone have any experience with this?```Step #2 - "migrate": ---------- CONNECT CLOUDSQL ----------Step #2 - "migrate": cloud_sql_proxy is running.Step #2 - "migrate": Connections: hardy-clover-******:europe-west3:db-dev-mccmsdemo.Step #2 - "migrate":Step #2 - "migrate": ---------- EXECUTE COMMAND ----------Step #2 - "migrate": sh .cloudbuild/django_migrate.shStep #2 - "migrate": 🎸 migrate postgres://*******:***********@127.0.0.1:3307/dbnameStep #2 - "migrate": Traceback (most recent call last):Step #2 - "migrate": File "/usr/local/lib/python3.8/site-packages/django/db/backends/base/base.py", line 219, in ensure_connectionStep #2 - "migrate": self.connect()Step #2 - "migrate": File "/usr/local/lib/python3.8/site-packages/django/utils/asyncio.py", line 26, in innerStep #2 - "migrate": return func(*args, **kwargs)Step #2 - "migrate": File "/usr/local/lib/python3.8/site-packages/django/db/backends/base/base.py", line 200, in connectStep #2 - "migrate": self.connection = self.get_new_connection(conn_params)Step #2 - "migrate": File "/usr/local/lib/python3.8/site-packages/django/utils/asyncio.py", line 26, in innerStep #2 - "migrate": return func(*args, **kwargs)Step #2 - "migrate": File "/usr/local/lib/python3.8/site-packages/django/db/backends/postgresql/base.py", line 187, in get_new_connectionStep #2 - "migrate": connection = Database.connect(**conn_params)Step #2 - "migrate": File "/usr/local/lib/python3.8/site-packages/psycopg2/__init__.py", line 127, in connectStep #2 - "migrate": conn = _connect(dsn, connection_factory=connection_factory, **kwasync)Step #2 - "migrate": psycopg2.OperationalError: could not connect to server: Connection refusedStep #2 - "migrate": Is the server running on host "127.0.0.1" and acceptingStep #2 - "migrate": TCP/IP connections on port 3307?Step #2 - "migrate":Step #2 - "migrate":Step #2 - "migrate": The above exception was the direct cause of the following exception:```
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/356b52f5-304b-43ea-b865-c1a03293d178n%40googlegroups.com.
No comments:
Post a Comment