3 # svnserve This shell script takes care of starting and stopping svnserve.
5 # chkconfig: 2345 80 30
6 # description: svnserve is a subversion server
8 # processname: svnserve
10 # Source function library.
11 . /etc/rc.d/init.d/functions
13 # Source networking configuration.
14 . /etc/sysconfig/network
16 # Source svnserve configureation.
17 [ -f /etc/sysconfig/svnserve ] && . /etc/sysconfig/svnserve
19 # Check that networking is up.
20 if is_yes "${NETWORKING}"; then
21 if [ ! -f /var/lock/subsys/network -a "$1" != stop -a "$1" != status ]; then
22 msg_network_down svnserve
31 if [ -f /var/lock/subsys/svnserve ]; then
32 msg_already_running svnserve
37 daemon --user svn svnserve ${SVNSERVE_OPTIONS} -r ${SVNSERVE_PATH}
39 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/svnserve
44 if [ ! -f /var/lock/subsys/svnserve ]; then
45 msg_not_running svnserve
51 rm -f /var/lock/subsys/svnserve >/dev/null 2>&1
56 if [ ! -f /var/lock/subsys/svnserve ]; then
57 msg_not_running svnserve
67 # See how we were called.
90 msg_usage "$0 {start|stop|restart|try-restart|force-reload|status}"