File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / quagga / pkgsrc / ripd.sh.in
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Tue Feb 21 17:26:11 2012 UTC (12 years, 10 months ago) by misho
Branches: quagga, MAIN
CVS tags: v1_0_20160315, v0_99_22p0, v0_99_22, v0_99_21, v0_99_20_1, v0_99_20, HEAD
quagga

#!/bin/sh
#
# ripd is part of the quagga routing beast
#
# PROVIDE: ripd
# REQUIRE: zebra
##

PATH=/sbin:/bin:/usr/sbin:/usr/bin:@prefix@/sbin:@prefix@/bin
export PATH

if [ -f /etc/rc.subr ]
then
	. /etc/rc.subr
fi

name="ripd"
rcvar=$name
required_files="@sysconfdir@/${name}.conf"
command="@prefix@/sbin/${name}"
command_args="-d"

start_precmd="zebra_precmd"
socket_dir=@localstatedir@
pidfile="${socket_dir}/${name}.pid"

zebra_precmd()
{
    rc_flags="$(
	set -- $rc_flags
	while [ $# -ne 0 ]; do
	    if [ X"$1" = X-P -o X"$1" = X-A ]; then
		break
	    fi
	    shift
	done
	if [ $# -eq 0 ]; then
	    echo "-P 0"
	fi
	) $rc_flags"
}

load_rc_config $name
run_rc_command "$1"

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>