projects
/
matthijs
/
upstream
/
backupninja-vserver.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
handlers/dup: now works when multiple vservers names are given (separated by space...
[matthijs/upstream/backupninja-vserver.git]
/
handlers
/
svn
diff --git
a/handlers/svn
b/handlers/svn
index 551255b943038d6226b95a97f6735a3b978541f5..26afafde504e4da30cf97b92d2a2c5cc7e405fcb 100644
(file)
--- a/
handlers/svn
+++ b/
handlers/svn
@@
-1,3
+1,4
@@
+# -*- mode: sh; sh-basic-offset: 3; indent-tabs-mode: nil; -*-
#
# this handler will backup subversion repostitories.
#
#
# this handler will backup subversion repostitories.
#
@@
-5,7
+6,7
@@
getconf src /var/lib/svn
getconf dest /var/backups/svn
getconf tmp /var/backups/svn.tmp
getconf src /var/lib/svn
getconf dest /var/backups/svn
getconf tmp /var/backups/svn.tmp
-getconf HOTBACKUP
/usr/lib/subversion/hot-backup.py
+getconf HOTBACKUP
"/usr/bin/svnadmin hotcopy"
getconf vsname
error=0
getconf vsname
error=0
@@
-23,11
+24,16
@@
then
fi
fi
fi
fi
-#
Check to make sure that the specified vserver exists
+#
If needed, make sure that the specified vserver exists and is running.
if [ $usevserver ]
then
if [ $usevserver ]
then
+ info "examining vserver '$vsname'"
+ # does it exist ?
vroot="$VROOTDIR/$vsname"
[ -d $vroot ] || fatal "vserver '$vsname' does not exist at '$vroot'"
vroot="$VROOTDIR/$vsname"
[ -d $vroot ] || fatal "vserver '$vsname' does not exist at '$vroot'"
+ # is it running ?
+ running=`$VSERVERINFO $vsname RUNNING`
+ [ "$running" = "1" ] || fatal "vserver $vsname is not running."
fi
cd $vroot$src
fi
cd $vroot$src