I am trying to set up temporal using helm chart and while setting up the Postgres database I am encountering this issue.
hema version compatibility check failed: pq: no pg_hba.conf entry for host "10.201.80.119", user "temporal_user", database "temporal", SSL off Unable to create server. Error: could not build arguments for function "go.uber.org/fx".(*module).constructCustomLogger.func2 (/home/runner/go/pkg/mod/go.uber.org/fx@v1.21.1/module.go:292): failed to build fxevent.Logger: could not build arguments for function "go.temporal.io/server/temporal".glob..func8 (/home/runner/work/docker-builds/docker-builds/temporal/temporal/fx.go:1009): failed to build log.Logger: received non-nil error from function "go.temporal.io/server/temporal".ServerOptionsProvider (/home/runner/work/docker-builds/docker-builds/temporal/temporal/fx.go:183): sql schema version compatibility check failed: pq: no pg_hba.conf entry for host "10.201.80.119", user "temporal_user", database "temporal", SSL off.
I can access the Postgres database from another pod in the same namespace. But cannot access the DB with temporal.I also tried to initialize the database through this
But even ./temporal-sql-tool cannot access the DB. But I can access it from my machine
SQL_DATABASE=temporal ./temporal-sql-tool setup-schema -v 0.0 2024-07-21T13:56:15.466+0200 ERROR sql handle: unable to refresh database connection pool {"error": "pq: no pg_hba.conf entry for host \"10.71.0.6\", user \"temporal_user\", database \"temporal\", SSL off", "logging-call-at": "db_handle.go:125"} 2024-07-21T13:56:15.468+0200 INFO Starting schema setup {"config": {"SchemaFilePath":"","SchemaName":"","InitialVersion":"0.0","Overwrite":false,"DisableVersioning":false}, "logging-call-at": "setuptask.go:64"} 2024-07-21T13:56:15.468+0200 DEBUG Setting up version tables {"logging-call-at": "setuptask.go:74"} 2024-07-21T13:56:15.468+0200 WARN sql handle: did not refresh database connection pool because the last refresh was too close {"min_refresh_interval_seconds": 1, "logging-call-at": "db_handle.go:116"} 2024-07-21T13:56:15.468+0200 ERROR Unable to setup SQL schema. {"error": "no usable database connection found", "logging-call-at": "handler.go:57"}