X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=plc.d%2Fpostgresql;h=1139af441be40c33b4b5a5cbf89cfb120e0d7224;hb=580734af3f0a37c12ace7909e6bf7978fe16778e;hp=a02ab5760a9bc141e7ef14fea7a10f4e8029f20e;hpb=b14d86c594355cd90334d2d353861c488817547d;p=plcapi.git diff --git a/plc.d/postgresql b/plc.d/postgresql index a02ab57..1139af4 100755 --- a/plc.d/postgresql +++ b/plc.d/postgresql @@ -95,7 +95,7 @@ case "$1" in ######## /var/lib/pgsql/data/pg_hba.conf # Disable access to MyPLC and drupal DBs from all hosts - sed -i -e '/^\(host\|local\)\s\($PLC_DB_NAME\|drupal\)/d' $pghba_conf + sed -i -e '/^\(host\|local\)/d' $pghba_conf # Enable passwordless localhost access echo "local all all trust" >>$pghba_conf @@ -152,7 +152,8 @@ case "$1" in if [ -z "$PLC_DB_PASSWORD" ] ; then PLC_DB_PASSWORD=$(uuidgen) plc-config --category=plc_db --variable=password --value="$PLC_DB_PASSWORD" --save=$local_config $local_config - service plc reload + #service plc reload + plc_reload force fi if ! psql -U $PLC_DB_USER -c "" template1 >/dev/null 2>&1 ; then psql -U postgres -c "CREATE USER $PLC_DB_USER PASSWORD '$PLC_DB_PASSWORD'" template1