X-Git-Url: https://git.stderr.nl/gitweb?a=blobdiff_plain;f=handlers%2Fsys.in;h=cc8ed095931fcaa6de46113ccd6ccd7caf1e0a1b;hb=c9136e6c5850d554cee4fab6a855975d0d4d5b4b;hp=cf4d77e756263e9097cd8b5419745e15ba1cbc3c;hpb=b1ddc9656e20c3a952b62597f40a097a134b47a3;p=matthijs%2Fupstream%2Fbackupninja-vserver.git diff --git a/handlers/sys.in b/handlers/sys.in index cf4d77e..cc8ed09 100755 --- a/handlers/sys.in +++ b/handlers/sys.in @@ -53,8 +53,8 @@ then getconf packagesfile $parentdir/dpkg-selections.txt getconf packagemgr `which dpkg` getconf packagemgroptions ' --get-selections *' - getconf selectionsfile $parentir/debconfsel.txt - getconf debconfgetselections `debconf-get-selections` + getconf selectionsfile $parentdir/debconfsel.txt + getconf debconfgetselections `which debconf-get-selections` elif [ $os = "redhat" ] then getconf packagesfile $parentdir/rpmpackages.txt @@ -126,11 +126,11 @@ if [ "$packages" == "yes" ]; then set +o noglob fi # is $debconfgetselections available inside $vserver ? - if [ ! -x "$VROOTDIR/$vserver`$VSERVER $vserver exec which $debconfgetselections`" ]; then - warning "can't find $debconfgetselections in vserver $vserver, skipping package selection states." + if [ -z "`$VSERVER $vserver exec which debconf-get-selections`" ]; then + warning "can't find debconf-get-selections in vserver $vserver, skipping package selection states." else debug "$VSERVER $vserver exec $debconfgetselections > $VROOTDIR/$vserver$selectionsfile" - $VSERVER $vserver exec $debconfgetselections > $VROOTDIR/$vserver$selectionsfile || fatal "can not save $debconfgetselections info to $selectionsfile" + $VSERVER $vserver exec $debconfgetselections > $VROOTDIR/$vserver$selectionsfile || fatal "can not save debconf-get-selections info to $selectionsfile" fi done fi