1 #!/bin/sh -e
2 #
3 # roundup Startup script for the roundup http server.
4 #
5 # Version: $Id: roundup.rc-debian,v 1.1 2003-10-07 23:02:58 richard Exp $
7 DESC='Roundup HTTP-Server'
9 BINFILE=roundup-server
10 EXECUTABLE=/usr/local/bin/$BINFILE
11 PIDFILE=/var/run/roundup/server.pid
12 LOGFILE=/var/log/roundup/roundup.log
13 TRACKERS=tttech=/tttech/org/software/roundup/tttech/
14 OPTIONS="-- -p 8080 -u roundup -d $PIDFILE -l $LOGFILE $TRACKERS"
17 test -x $EXECUTABLE || exit 0
19 start_stop() {
20 case "$1" in
21 start)
22 printf "Starting $DESC:"
23 start-stop-daemon --start --oknodo --quiet \
24 --pidfile $PIDFILE \
25 --exec $EXECUTABLE $OPTIONS
26 printf " $BINFILE"
27 printf ".\n"
28 ;;
29 stop)
30 printf "Stopping $DESC:"
31 start-stop-daemon --stop --oknodo --quiet \
32 --pidfile $PIDFILE \
33 --exec $EXECUTABLE $OPTIONS
34 printf " $BINFILE"
35 printf ".\n"
36 ;;
37 restart | force-reload)
38 start_stop stop
39 sleep 1
40 start_stop start
41 ;;
42 *)
43 printf "Usage: $0 {start|stop|restart|force-reload}\n" >&2
44 exit 1
45 ;;
46 esac
47 }
49 start_stop "$@"
51 exit 0