do not remove local bk if upload failed
This commit is contained in:
12
zfsbk.sh
12
zfsbk.sh
@ -114,11 +114,11 @@ then
|
||||
echo "Expecting rsync://.. or scp://.."
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# remove backup file if requested
|
||||
if [ "x$CLEAR_BKFILE" != x ]
|
||||
then
|
||||
rm -f $bkfile
|
||||
# remove local backup if requested & upload was successful
|
||||
if [ $? -eq 0 -a "x$CLEAR_BKFILE" != x ]
|
||||
then
|
||||
# remove backup file if requested
|
||||
rm -f $bkfile
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user