diff --git a/files/postgres/pg_hba.conf b/files/postgres/pg_hba.conf new file mode 100644 index 0000000..589f81a --- /dev/null +++ b/files/postgres/pg_hba.conf @@ -0,0 +1,6 @@ +# Before editing this file, please refer to official doc: +# https://www.postgresql.org/docs/current/auth-pg-hba-conf.html + +# TYPE DATABASE USER ADDRESS METHOD +local sameuser all peer # Allow each unix user accessing its own db +local all postgres peer # Allow postgres user accessing all dbs diff --git a/files/postgres/postgresql.conf b/files/postgres/postgresql.conf new file mode 100644 index 0000000..3bc89f1 --- /dev/null +++ b/files/postgres/postgresql.conf @@ -0,0 +1,19 @@ +#------------------------------------------------------------------------------- +# FILE LOCATIONS +# Please refer to official doc before editing this section: +# https://www.postgresql.org/docs/current/runtime-config-file-locations.html +#------------------------------------------------------------------------------- + +# Change pg_hba location +hba_file = "/etc/postgres/pg_hba.conf" + + +#------------------------------------------------------------------------------- +# CONNECTIONS AND AUTHENTICATION +# Please refer to official doc before editing this section: +# https://www.postgresql.org/docs/current/runtime-config-connection.html +#------------------------------------------------------------------------------- + +# Empty listen addresses to disable listening via TCP/IP +# because we want only uni socket connections +listen_addresses = ""