Re: CREATE SUBSCRIPTION not picking up .pgpass while psql does

From: hubert depesz lubaczewski <depesz(at)depesz(dot)com>
To: Kristjan Mustkivi <sonicmonkey(at)gmail(dot)com>
Cc: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: CREATE SUBSCRIPTION not picking up .pgpass while psql does
Date: 2022-08-31 13:27:58
Message-ID: 20220831132757.GA28040@depesz.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Aug 31, 2022 at 04:26:22PM +0300, Kristjan Mustkivi wrote:
> And as said, the psql utility has no problems finding the .pgass where
> it is. If I lie to it about the pgpass location i.e by giving
> passfile=/root/.pgpassx it will ask for password.

of course it doesn't have problem, because you run it as root.
put subscription is run by pg backend, which runs as postgres user, not
root!

also - no pg tool cares about "passfile" env variable, so it is just
ignored.

Best regards,

depesz

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Kristjan Mustkivi 2022-08-31 13:39:02 Re: CREATE SUBSCRIPTION not picking up .pgpass while psql does
Previous Message Kristjan Mustkivi 2022-08-31 13:26:22 Re: CREATE SUBSCRIPTION not picking up .pgpass while psql does