]> gitweb.fluxo.info Git - puppet-backup.git/commitdiff
Fixing rsync-check
authorSilvio Rhatto <rhatto@riseup.net>
Wed, 18 Aug 2010 20:48:55 +0000 (17:48 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Wed, 18 Aug 2010 20:48:55 +0000 (17:48 -0300)
templates/rsync-check.sh.erb

index e945b8cc1a7e5a4e77a588c300095eebb8e5ac5d..879faaf59baee3da996f10659e59bbe2efccb683 100644 (file)
@@ -21,12 +21,15 @@ if [ -e "$BACKUP_FOLDER" ]; then
       cat  $metadata
     done
 
+    # Check duplicity metadata
     if [ -d "$set/<%= backupdir %>/duplicity" ]; then
-      echo " "
-      echo "Checking duplicity backup found at $set/<%= backupdir %>/duplicity..."
-      echo "======================================================"
-      echo " "
-      duplicity collection-status file:///$BACKUP_FOLDER/$set/<%= backupdir %>/duplicity
+      for duplicity in `ls -1 $set/<%= backupdir %>/duplicity | grep -v metadata | xargs`; do
+        echo " "
+        echo "Checking duplicity backup found at $set/<%= backupdir %>/duplicity/$duplicity..."
+        echo "======================================================"
+        echo " "
+        duplicity collection-status file:///$BACKUP_FOLDER/$set/<%= backupdir %>/duplicity/$duplicity
+      done
     fi
   done