Use absolute paths to rsnapshot if possible

This commit is contained in:
Janek Bevendorff 2014-10-06 13:54:33 +02:00
parent 917966b2af
commit 1d1a09f89a
1 changed files with 7 additions and 1 deletions

View File

@ -37,5 +37,11 @@ if [ "$RSYNC_EXIT_STATUS" == "" ]; then
fi
if [ $RSYNC_EXIT_STATUS -eq 0 ] || [ $RSYNC_EXIT_STATUS -eq 24 ]; then
rsnapshot -c "$1" push
RSNAPSHOT="rsnapshot"
if [ -x /usr/bin/rsnapshot ]; then
RSNAPSHOT="/usr/bin/rsnapshot"
elif [ -x /opt/bin/rsnapshot ]; then
RSNAPSHOT="/opt/bin/rsnapshot"
fi
$RSNAPSHOT -c "$1" push
fi