I am trying to setup django with postgres on app engine flexible environment.
I followed the instructions from here: https://cloud.google.com/appengine/docs/flexible/python/using-cloud-sql-postgres
My django settings:
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.postgresql',
'NAME': '<db-name>',
'USER': '<user-name>',
'PASSWORD': '<password>',
'HOST': '/cloudsql/<instance-connection-name>,
'PORT': '5432'
},
}
app.yaml:
beta_settings:
cloud_sql_instances: <instance-connection-name>
Error I am getting is:
could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/cloudsql/
<instance-connection-name>
/.s.PGSQL.5432"?
Please help with the correct settings.