From 3f397ff1575b79f74184302f3c3b8e549895f571 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Wed, 4 Jan 2012 18:43:33 -0200 Subject: Adding backup/copy sites; restoration fixes --- lib/hydra/backup | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'lib/hydra/backup') diff --git a/lib/hydra/backup b/lib/hydra/backup index 9c35ff9..e3edf50 100644 --- a/lib/hydra/backup +++ b/lib/hydra/backup @@ -2,10 +2,11 @@ # Setup environment for the backups website function hydra_backup_environment_local_website { - SITE="$1" - BACKUPDIR="/var/sites/backups/site/$SITE" + NODE="$1" + SITE="$2" + BACKUPDIR="/var/sites/backups/site/$SITE/$NODE" - if [ -z "$SITE" ]; then + if [ -z "$SITE" ] || [ -z "$NODE" ]; then hydra_action_usage exit 1 fi @@ -61,10 +62,10 @@ function hydra_backup_environment_remote { if [ -z "$METHOD" ]; then if [ -d "$BACKUPDIR/rsync" ]; then echo "Assuming rsync backup method" - BACKUPDIR="$BACKUPDIR/rsync" + BACKUPDIR="$BACKUPDIR/rsync/var/backups/duplicity/daily.1" elif [ -d "$BACKUPDIR/rdiff" ]; then echo "Assuming rdiff backup method" - BACKUPDIR="$BACKUPDIR/rdiff" + BACKUPDIR="$BACKUPDIR/rdiff/var/backups/duplicity" else echo "Missing backup action" exit 1 -- cgit v1.2.3