Sophie

Sophie

distrib > Mandriva > 2008.1 > x86_64 > by-pkgid > 27a016b9df8ad09a586e05652eb0c5c1 > files > 2

timevault-0.7.5-2mdv2008.1.x86_64.rpm

#!/bin/sh
#
# chkconfig: 345 99 10
# description: Timevault daemon

# Installed with:
# update-rc.d timevault defaults

NAME=timevault
CMD=/usr/bin/$NAME
ARGS="--verbose"
NICE=0

# Exit silently if package is no longer installed
[ -x $CMD ] || exit 0

. /lib/lsb/init-functions

case "$1" in
start)
	gprintf "Starting TimeVault..."
	start-stop-daemon --start --background --pidfile /var/run/$NAME.pid --nicelevel $NICE --exec $CMD -- $ARGS || log_failure_msg
	log_success_msg
	;;
stop)
	gprintf "Stopping TimeVault..."
	start-stop-daemon --stop --quiet --pidfile /var/run/$NAME.pid || log_failure_msg
	log_success_msg
	;;
reload|restart|force-reload)
	$0 stop || EXITSTATUS=1
	$0 start || EXITSTATUS=1
	exit $EXITSTATUS
	;;
*)
	echo "Usage: $NAME {start|stop|restart|force-restart}" >&2
	exit 3
	;;
esac

exit 0