From c9a92fd4f71c3341d9f4fd8c40edad5dc2707b78 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Sat, 17 Feb 2018 15:19:59 +0000 Subject: [PATCH] Use agent during verification --- src/freedombone-utils-backup | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/freedombone-utils-backup b/src/freedombone-utils-backup index f38444a7..a5b1f0d6 100755 --- a/src/freedombone-utils-backup +++ b/src/freedombone-utils-backup @@ -296,7 +296,7 @@ function backup_directory_to_usb_duplicity { exit 8352925 fi if [[ $ENABLE_BACKUP_VERIFICATION == "yes" ]]; then - echo "$BACKUP_DUMMY_PASSWORD" | duplicity verify --gpg-options "$BACKUP_GPG_OPTIONS" --tempdir $BACKUP_TEMP_DIRECTORY --encrypt-key $MY_BACKUP_KEY_ID --full-if-older-than 4W --exclude-other-filesystems ${1} file://$USB_MOUNT/backup/${2} + echo "$BACKUP_DUMMY_PASSWORD" | duplicity verify --use-agent --gpg-options "$BACKUP_GPG_OPTIONS" --tempdir $BACKUP_TEMP_DIRECTORY --encrypt-key $MY_BACKUP_KEY_ID --full-if-older-than 4W --exclude-other-filesystems ${1} file://$USB_MOUNT/backup/${2} if [ ! "$?" = "0" ]; then umount $USB_MOUNT rm -rf $USB_MOUNT @@ -424,7 +424,7 @@ function backup_directory_to_friend_duplicity { exit 5293526 fi if [[ $ENABLE_BACKUP_VERIFICATION == "yes" ]]; then - echo "$BACKUP_DUMMY_PASSWORD" | duplicity verify --gpg-options "$BACKUP_GPG_OPTIONS" --tempdir $BACKUP_TEMP_DIRECTORY --ssh-askpass --encrypt-key ${ADMIN_BACKUP_KEY_ID} --full-if-older-than 4W --exclude-other-filesystems ${1} $SERVER_DIRECTORY/backup/${2} + echo "$BACKUP_DUMMY_PASSWORD" | duplicity verify --use-agent --gpg-options "$BACKUP_GPG_OPTIONS" --tempdir $BACKUP_TEMP_DIRECTORY --ssh-askpass --encrypt-key ${ADMIN_BACKUP_KEY_ID} --full-if-older-than 4W --exclude-other-filesystems ${1} $SERVER_DIRECTORY/backup/${2} if [ ! "$?" = "0" ]; then if [[ ${1} == "/root/temp"* || ${1} == *"tempbackup" ]]; then shred -zu ${1}/*