Friday, October 1, 2021

How to Configure PostgreSQL to Accept All Incoming Connections


Edit pg_hba.conf

Just use 0.0.0.0/0

host    all             all             0.0.0.0/0            md5

Make sure the listen_addresses in postgresql.conf (or ALTER SYSTEM SET) allows incoming connections on all available IP interfaces.

listen_addresses = '*'

After the changes you have to reload the configuration. One way to do this is execute this SELECT as a superuser.

SELECT pg_reload_conf();

** Note: to change listen_addresses, a reload is not enough, and you have to restart the server.


Reference :


Latest
Next Post

0 komentar: