File: roundup-ctl

package info (click to toggle)
roundup 1.2.1-10%2Betch1
  • links: PTS
  • area: main
  • in suites: etch
  • size: 4,764 kB
  • ctags: 3,756
  • sloc: python: 30,296; sh: 1,497; perl: 23; makefile: 22
file content (28 lines) | stat: -rw-r--r-- 503 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/bin/sh -e

PATH=/sbin:/bin:/usr/sbin:/usr/bin
NAME=roundup
DESC="roundup server"
if [ "x$1" = "x-d" ]; then
    shift
    SERVICE="$1"
    shift
else
    SERVICE=/var/service/$NAME
fi

if [ -d "$SERVICE" ]; then
    case "$1" in
      start|stop|reload|force-reload|restart|status)
        sv -v "$1" ${NAME}
	;;
      *)
	echo "Usage: roundup-ctl {start|stop|restart|reload|force-reload|status}" >&2
	exit 3
	;;
    esac
else
    echo "roundup-ctl: $SERVICE is not a directory"
    exit 1
fi
exit 0