cannot make simplest pgbouncer / postgresql combo work using default unix sockets.
logged in as foo, with an existent database (created by foo) bar. these work fine:
$ psql bar $ psql -U foo bar $ psql -U foo --password bar
in /etc/pgbouncer/userlist.txt:
"foo" "foo"
in /etc/pgbouncer/pgbouncer.ini:
[databases] mydb = [pgbouncer] unix_socket_dir = /var/run/postgresql auth_type = trust auth_file = /etc/pgbouncer/userlist.txt
when I try to login with psql -p 6432 mydb or with psql -p 6432 mydb --password, after entering password, I get
psql: ERROR: Peer authentication failed for user "foo"