diff options
author | Remko van der Vossen | 2011-04-02 23:32:00 +0200 |
---|---|---|
committer | Remko van der Vossen | 2011-04-02 23:32:00 +0200 |
commit | 39a456558dcf5e8c669089b769fe5c5abfd474d6 (patch) | |
tree | 6f99dd0ad630e47d6c54e6c45accfc5a12a633f6 | |
parent | 4473f7943b4f89b50d4065242536edcb59db91c1 (diff) |
subversion: added init script
-rw-r--r-- | collab/subversion/HISTORY | 3 | ||||
-rwxr-xr-x | collab/subversion/init.d/subversion | 21 | ||||
-rw-r--r-- | collab/subversion/init.d/subversion.conf | 20 |
3 files changed, 44 insertions, 0 deletions
diff --git a/collab/subversion/HISTORY b/collab/subversion/HISTORY index d4850b24fd..dde3e45732 100644 --- a/collab/subversion/HISTORY +++ b/collab/subversion/HISTORY @@ -1,3 +1,6 @@ +2011-04-02 Remko van der Vossen <wich@sourcemage.org> + * init.d/subverion{,.conf}: added init script + 2011-03-04 Ladislav Hagara <hgr@vabo.cz> * DETAILS: 1.6.16, SECURITY_PATCH=1 http://subversion.apache.org/security/CVE-2011-0715-advisory.txt diff --git a/collab/subversion/init.d/subversion b/collab/subversion/init.d/subversion new file mode 100755 index 0000000000..13f437e7e0 --- /dev/null +++ b/collab/subversion/init.d/subversion @@ -0,0 +1,21 @@ +#!/bin/bash + +. /etc/sysconfig/subversion + +PIDFILE=/var/run/subversion.pid +PROGRAM=/usr/bin/svnserve +RUNLEVEL=3 +NEEDS="+network +remote_fs" + +OPTS="-d --pid-file $PIDFILE -r $REPOSITORIES" +[[ -n "$LISTEN_HOST" ]] && OPTS="$OPTS --listen-host=$LISTEN_HOST" +[[ -n "$LISTEN_PORT" ]] && OPTS="$OPTS --listen-port=$LISTEN_PORT" +[[ "$READ_ONLY" =~ "^[Yy].*$" ]] && OPTS="$OPTS -R" +[[ "$THREADS" =~ "^[Yy].*$" ]] && OPTS="$OPTS -T" + +. /etc/init.d/smgl_init + +start() +{ + loadproc "${PROGRAM}" $OPTS +} diff --git a/collab/subversion/init.d/subversion.conf b/collab/subversion/init.d/subversion.conf new file mode 100644 index 0000000000..f6f7206cd2 --- /dev/null +++ b/collab/subversion/init.d/subversion.conf @@ -0,0 +1,20 @@ +# Location of the SVN Repositories +REPOSITORIES="/srv/svn/repositories" + +# Listening Host +# Either a hostname or IP address that the server binds to +# Defaults to 0.0.0.0 if unspecified +LISTEN_HOST="" + +# Listening Port +# Defaults to 3690 if unspecified +LISTEN_PORT="" + +# Read Only +# Controls whether the server is in read-only mode or not +READ_ONLY="NO" + +# Threading +# Controllers whether the server uses thread to handle request, as opposed to +# forked processes +THREADS="NO" |