mirror of
https://0xacab.org/liberate/backupninja.git
synced 2024-11-10 04:42:31 +01:00
pgsql: postgres user UID is now the one from inside the vserver if necessary
This commit is contained in:
parent
806d97652f
commit
a8c5734f54
@ -14,6 +14,7 @@ version 0.9.4 -- unreleased
|
||||
. Fixed inversed vsname emptiness check
|
||||
. Fixed su quote usage to be more posixy
|
||||
. Fixed shell expansion, thanks Thomas Kotzian (Closes: #363297)
|
||||
. postgres user UID is now the one from inside the vserver if necessary
|
||||
svn:
|
||||
. Fixed inversed vsname emptiness check
|
||||
rdiff:
|
||||
|
@ -61,7 +61,11 @@ fi
|
||||
|
||||
# give backup dir the good uid and permissions
|
||||
# (in respect to the vserver, if $usevserver = yes)
|
||||
pguid=`getent passwd postgres | awk -F: '{print $3}'`
|
||||
if [ $usevserver = yes ]; then
|
||||
pguid=`$VSERVER $vsname exec getent passwd postgres | awk -F: '{print $3}'`
|
||||
else
|
||||
pguid=`getent passwd postgres | awk -F: '{print $3}'`
|
||||
fi
|
||||
[ -n "$pguid" ] || \
|
||||
fatal "No user called postgres`[ $usevserver = no ] || echo \" on vserver $vsname\"`."
|
||||
debug "chown $pguid $vroot$backupdir"
|
||||
|
Loading…
Reference in New Issue
Block a user