1
0
Fork 0

Small adjustments to restic-backup

Reflect status of script from the VPS, mainly add a sleep interval after backup.
This commit is contained in:
Teo-CD 2022-04-18 10:22:53 +01:00
parent ce261fa71f
commit a278fdd40a

View file

@ -2,7 +2,7 @@
# Use setcap'd binary in home directory # Use setcap'd binary in home directory
#PATH="/home/restic/bin/:$PATH" #PATH="/home/restic/bin/:$PATH"
# Now uses binary in /usr/bin, which is also setcap'd #Not necessary anymore : binary in /usr/bin setcap'd
backup_origin="/backups/restic" backup_origin="/backups/restic"
backup_container="central-backup" backup_container="central-backup"
@ -64,6 +64,9 @@ if [ $? -ne 0 ]; then
error_message="$error_message""$(cat backup_output.log)" error_message="$error_message""$(cat backup_output.log)"
fi fi
# Sleep to allow time for propagation
sleep 60
if [ -z "$error_message" ]; then if [ -z "$error_message" ]; then
restic check --verbose > check_output.log 2>&1 restic check --verbose > check_output.log 2>&1
fi fi