zalando / zalando/postgres-operator

Unable to connect application user to acid-minimal-cluster due to pg_hba.conf

Open
#2,287 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

question
Dominant language
Go
Stars
5.2k
Forks
1.1k
Avg merge
2d 16h
Merged PRs (30d)
3

Description

Please, answer some short questions which should help us to understand your problem / question better?

  • *registry.opensource.zalan.do/acid/postgres-operator:v1.9.0
  • Where do you run it - cloud or metal? Kubernetes or OpenShift? [microk8s VM]
  • Are you running Postgres Operator in production? [no, not yet]
  • Type of issue? [issue with application connection.]

The operator is working fine, and most likely something I need to configure: I've created a simple two-node cluster (acid-minimal-cluster) and specified an application user which can connect locally, but not through the service with the error:

psql -U project_victor app-db-name -W -h acid-minimal-cluster-repl
Password: 
psql: error: connection to server at "acid-minimal-cluster-repl" (10.152.183.203), port 5432 failed: FATAL:  password authentication failed for user "project_victor"
connection to server at "acid-minimal-cluster-repl" (10.152.183.203), port 5432 failed: FATAL:  pg_hba.conf rejects connection for host "10.1.76.169", user "project_victor", database "app-db-name", no encryption

What do I need to specify so that the user is allowed to connect through the service?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the acid-minimal-cluster configuration and the application user settings described in the issue, then compare the local connection with the service connection and the reported pg_hba.conf error. Done means identifying the missing configuration that permits project_victor to connect through acid-minimal-cluster-repl and verifying the connection succeeds.

Written by the indexing model from the issue text.

Assessment

Tech stack
kubernetes, postgresql
Domain
databases, infrastructure, networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.