#!/sbin/runscript # Copyright 1999-2009 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/net-misc/orbited/files/orbited.init,v 1.1 2009/08/30 11:44:46 caleb Exp $ depend() { need net use dns } checkconfig() { if [ ! -f "/etc/orbited.cfg" ] ; then eerror "No /etc/orbited.cfg file exists!" fi } start() { checkconfig || return 1 ebegin "Starting orbited..." /usr/bin/orbited --config=/etc/orbited.cfg >/dev/null 2>&1 & pid=$! echo $pid > /var/run/orbited.pid eend $? } stop() { ebegin "Stopping orbited..." start-stop-daemon --stop --quiet --pidfile=/var/run/orbited.pid --retry 20 eend $? }