#!/bin/sh # # svnserve.sh for rc.d usage (c) 2005 Thomas E. Spanjaard. # $Id$ # PROVIDE: svnserve # REQUIRE: DAEMON # BEFORE: LOGIN # KEYWORD: shutdown # # Add the following line to /etc/rc.conf to enable SVNServe: # # svnserve_enable="YES" # # optional # svnserve_flags="-d --listen-port=3690 --listen-host 0.0.0.0" # svnserve_data="/usr/local/repositories" # svnserve_user="svn" # svnserve_group="svn" # # Note: # svnserve bind per default at the ipv6 address! # If you want svnserve binding at ipv4 address, you have # to use option 'svnserve_flags' with --listen-host parameter . /etc/rc.subr # Set some defaults svnserve_enable=${svnserve_enable:-"NO"} svnserve_flags=${svnserve_flags:-"-d --listen-port=3690 --listen-host 0.0.0.0"} svnserve_data=${svnserve_data:-"/home/svn/repos"} svnserve_user=${svnserve_user:-"svn"} svnserve_group=${svnserve_group:-"svn"} name=svnserve rcvar=svnserve_enable load_rc_config $name command=%%PREFIX%%/bin/svnserve%%SVNSERVE_BIN_EXT%% command_args="-r ${svnserve_data}" run_rc_command "$1"