On Tue, Oct 17, 2017 at 09:06:59AM +0300, Allan Kamau wrote: > Is there a way to instruct psql not to try reading ~/.pgpass file?
https://www.postgresql.org/docs/current/static/libpq-envars.html PGPASSFILE behaves the same as the passfile connection parameter. passfile Specifies the name of the file used to store passwords (see Section 33.15). Defaults to ~/.pgpass, or %APPDATA%\postgresql\pgpass.conf on Microsoft Windows. (No error is reported if this file does not exist.) https://www.postgresql.org/docs/9.6/static/libpq-envars.html PGPASSFILE specifies the name of the password file to use for lookups. If not set, it defaults to ~/.pgpass (see Section 31.15). verifying it doesn't access the default: pryzbyj@pryzbyj:~$ echo quit |PGPASSFILE=/nonextant strace psql 2>&1 |grep -E 'nonex|pgpass' stat("/nonextant", 0x7fffbd13c9f0) = -1 ENOENT (No such file or directory) pryzbyj@pryzbyj:~$ -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general