From bc3069d78409aa0b3fdee55819e123c0b72bde3a Mon Sep 17 00:00:00 2001 From: didier Date: Mon, 14 Oct 2024 08:57:47 +0200 Subject: [PATCH] correction de l'exclusion des fichiers de sauvegardes --- bin/scriptBorg.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/scriptBorg.sh b/bin/scriptBorg.sh index bf28f09..e38f671 100755 --- a/bin/scriptBorg.sh +++ b/bin/scriptBorg.sh @@ -121,6 +121,7 @@ Post_Sauvegarde() { } Sauvegarde() { + [ -f "${BORG_EXCLUDE_BACKUP}" ] && S_EXCU="--exclude-from ${BORG_EXCLUDE_BACKUP}" || S_EXCU="" Pre_Sauvegarde BACKUP_PRE=$? borg create \ @@ -130,7 +131,7 @@ Sauvegarde() { --show-rc \ --exclude 'home/*/.cache/*' \ --exclude 'var/tmp/*' \ - --exclude-from ${BORG_EXCLUDE_BACKUP}\ + ${S_EXCU} \ ::$(date +%Y-%m-%d-%H-%M-%S-%A)-{hostname} \ ${LISTREPSAUV} >>${BORGLOG} 2>>${BORGLOG} BACKUP_EXIT=$?