diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2012-07-22 17:20:24 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2012-07-22 17:20:24 -0300 |
commit | 8b9259f6baa1804576e97a98be7fef23caaca6f0 (patch) | |
tree | 4e8b3625e88599fb459b48d94e45ce1c359c41cb /share/hydractl/backup-restore-database | |
parent | 04ffe1502183039ffcefa391573f356f8e398a9c (diff) | |
download | hydra-8b9259f6baa1804576e97a98be7fef23caaca6f0.tar.gz hydra-8b9259f6baa1804576e97a98be7fef23caaca6f0.tar.bz2 |
Support also database restoration from backups site
Diffstat (limited to 'share/hydractl/backup-restore-database')
-rwxr-xr-x | share/hydractl/backup-restore-database | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/share/hydractl/backup-restore-database b/share/hydractl/backup-restore-database index 996760a..f7fe1c3 100755 --- a/share/hydractl/backup-restore-database +++ b/share/hydractl/backup-restore-database @@ -27,7 +27,10 @@ DATABASE="$2" BASEDIR="/tmp" # Check restore strategy. -if [ "$HOST" == "localhost" ] || [ "$HOST" == "`facter hostname`" ]; then +if [ "$1" == "backups" ]; then + DATABASE="$3" + hydra_backup_environment_local_website $2 $3 +elif [ "$HOST" == "localhost" ] || [ "$HOST" == "`facter hostname`" ]; then hydra_backup_environment_local else hydra_backup_environment_remote $HOST restore |