From 42ce6de0c3d14388515d85dd766ed8bd3452179f Mon Sep 17 00:00:00 2001 From: Jukka Ruohonen Date: Fri, 9 Nov 2007 13:59:44 +0000 Subject: net-analyzer/daemonlogger: Added init scripts and modified the ebuild accordingly. svn path=/sunrise/; revision=5034 --- net-analyzer/daemonlogger/files/daemonlogger-initd | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 net-analyzer/daemonlogger/files/daemonlogger-initd (limited to 'net-analyzer/daemonlogger/files/daemonlogger-initd') diff --git a/net-analyzer/daemonlogger/files/daemonlogger-initd b/net-analyzer/daemonlogger/files/daemonlogger-initd new file mode 100644 index 000000000..3d8c36af3 --- /dev/null +++ b/net-analyzer/daemonlogger/files/daemonlogger-initd @@ -0,0 +1,26 @@ +#!/sbin/runscript +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +if [[ -n "${TAP}" ]] ; then + DAEMONLOGGER_OPTS="${DAEMONLOGGER_OPTS} -o ${TAP}" +fi + +depend() { + need net +} + +start() { + ebegin "Starting daemonlogger on ${IFACE}" + start-stop-daemon --start --exec /usr/sbin/daemonlogger \ + --pidfile /var/run/daemonlogger_$IFACE.pid --background \ + -- -P /var/run -p daemonlogger_$IFACE.pid ${DAEMONLOGGER_OPTS} + eend $? +} + +stop() { + ebegin "Stopping daemonlogger on ${IFACE}" + start-stop-daemon --stop --quiet --retry 5 --pidfile /var/run/daemonlogger_$IFACE.pid + eend $? +} -- cgit v1.2.3-65-gdbad