--- /dev/null
+#!/bin/sh
+#
+# svnserve This shell script takes care of starting and stopping svnserve.
+#
+# chkconfig: 2345 80 30
+# description: svnserve is a subversion server
+#
+# processname: svnserve
+# config:
+# pidfile:
+
+# Source function library.
+. /etc/rc.d/init.d/functions
+
+# Source networking configuration.
+. /etc/sysconfig/network
+
+# Source svnserve configureation.
+[ -f /etc/sysconfig/svnserve ] && . /etc/sysconfig/svnserve
+
+# Check that networking is up.
+if is_yes "${NETWORKING}"; then
+ if [ ! -f /var/lock/subsys/network -a "$1" != stop -a "$1" != status ]; then
+ msg_network_down svnserve
+ exit 1
+ fi
+else
+ exit 0
+fi
+
+RETVAL=0
+# See how we were called.
+case "$1" in
+ start)
+ # Start daemons.
+ if [ ! -f /var/lock/subsys/svnserve ]; then
+ msg_starting svnserve
+ daemon svnserve ${SVNSERVE_OPTIONS}
+ RETVAL=$?
+ [ $RETVAL -eq 0 ] && touch /var/lock/subsys/svnserve
+ else
+ msg_already_running svnserve
+ fi
+ ;;
+ stop)
+ # Stop daemons.
+ if [ -f /var/lock/subsys/svnserve ]; then
+ msg_stopping svnserve
+ killproc svnserve
+ rm -f /var/lock/subsys/svnserve >/dev/null 2>&1
+ else
+ msg_not_running svnserve
+ fi
+ ;;
+ restart|force-reload)
+ $0 stop
+ $0 start
+ exit $?
+ ;;
+ status)
+ status svnserve
+ exit $?
+ ;;
+# reload)
+# msg_reloading svnserve
+# killproc svnserve -HUP
+# ;;
+ *)
+ msg_usage "$0 {start|stop|restart|force-reload|status}"
+ exit 3
+esac
+
+exit $RETVAL
--- /dev/null
+## Type: string
+## Default "-d -R -r /srv/svn/repos"
+#
+# default options for the svnserve process
+# it is recommended to provide only readonly access to your data.
+# there is no authentication possible, everyone can read and write at will
+# read the subversion documentation about more info
+#
+SVNSERVE_OPTIONS="-d -R -r /srv/svn/repos"