aboutsummaryrefslogtreecommitdiff
path: root/lib/hydra/backup
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2014-03-11 13:43:50 -0300
committerSilvio Rhatto <rhatto@riseup.net>2014-03-11 13:43:50 -0300
commitfa60b3cbc4327201165fba7dc8a5538d4859e7c3 (patch)
treec6efdf2d233e445ba0c5f3ebe27c1da5d520cd3a /lib/hydra/backup
parent1e4b2aead3632aa1b50363ae5a8adc20a900e130 (diff)
downloadhydra-fa60b3cbc4327201165fba7dc8a5538d4859e7c3.tar.gz
hydra-fa60b3cbc4327201165fba7dc8a5538d4859e7c3.tar.bz2
Fix RESTOREDIR at hydra_backup_environment_local_website
Diffstat (limited to 'lib/hydra/backup')
-rw-r--r--lib/hydra/backup2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/hydra/backup b/lib/hydra/backup
index 0fb6e80..000bc5a 100644
--- a/lib/hydra/backup
+++ b/lib/hydra/backup
@@ -19,7 +19,7 @@ function hydra_backup_environment_local_website {
# Try to get the newest if there's no backup for the current date
if [ ! -e "$RESTOREDIR/$SITE.tar.bz2" ]; then
- RESTOREDIR="$(find $BACKUPDIR -name "$SITE.tar.bz2" | sort -n | tail -n 1)"
+ RESTOREDIR="$(find $BACKUPDIR -name "$SITE.tar.bz2" -exec dirname {} \; | sort -n | tail -n 1)"
if [ -z "$RESTOREDIR" ]; then
echo "Backup not found for $DATE."