mirror of
https://github.com/wassname/docker-postgresql.git
synced 2026-06-28 04:05:50 +08:00
start: clean up
This commit is contained in:
@@ -32,17 +32,18 @@ cat >> ${PG_CONFDIR}/postgresql.conf <<EOF
|
||||
listen_addresses = '*'
|
||||
EOF
|
||||
|
||||
trust_local="host all all samenet trust"
|
||||
if [ ${PSQL_TRUST_LOCALNET} = "true" ]; then
|
||||
echo "Enabling trust samenet in pg_hba.conf..."
|
||||
echo ${trust_local} >> ${PG_CONFDIR}/pg_hba.conf
|
||||
fi
|
||||
|
||||
# allow remote connections to postgresql database
|
||||
cat >> ${PG_CONFDIR}/pg_hba.conf <<EOF
|
||||
host all all 0.0.0.0/0 md5
|
||||
EOF
|
||||
|
||||
if [ ${PSQL_TRUST_LOCALNET} = "true" ]; then
|
||||
echo "Enabling trust samenet in pg_hba.conf..."
|
||||
cat >> ${PG_CONFDIR}/pg_hba.conf <<EOF
|
||||
host all all samenet trust
|
||||
EOF
|
||||
fi
|
||||
|
||||
cd ${PG_HOME}
|
||||
|
||||
# initialize PostgreSQL data directory
|
||||
|
||||
Reference in New Issue
Block a user