wok view cherokee/stuff/cherokee @ rev 14909

slitaz-i18n: add slitaz-configs as bdep; slitaz-configs: back openbox menu; locale-el, locale-ru: add keyboard layout icons; locale-fr, locale-hu, locale-pt_BR: recook with openbox menu.
author Aleksej Bobylev <al.bobylev@gmail.com>
date Mon Aug 05 11:40:01 2013 +0300 (2013-08-05)
parents
children e8c594a6b672
line source
1 #!/bin/sh
2 # /etc/init.d/cherokee: Start, stop and restart Cherokee web server on SliTaz,
3 # at boot time or with the command line. Daemons options are configured
4 # with /etc/daemons.conf
5 #
6 . /etc/init.d/rc.functions
7 . /etc/daemons.conf
9 NAME=Cherokee
10 DESC="Cherokee Web Server"
11 DAEMON=/usr/sbin/cherokee
12 OPTIONS=
13 PIDFILE=/var/run/cherokee.pid
15 case "$1" in
16 start)
17 if active_pidfile $PIDFILE cherokee ; then
18 echo "$NAME already running."
19 exit 1
20 fi
21 echo -n "Starting $DESC: $NAME... "
22 $DAEMON $OPTIONS -k start
23 status
24 ;;
25 stop)
26 if ! active_pidfile $PIDFILE cherokee ; then
27 echo "$NAME is not running."
28 exit 1
29 fi
30 echo -n "Stopping $DESC: $NAME... "
31 $DAEMON $OPTION -k stop
32 rm $PIDFILE
33 status
34 ;;
35 reload)
36 if ! active_pidfile $PIDFILE cherokee ; then
37 echo "$NAME is not running."
38 exit 1
39 fi
40 echo -n "Stopping $DESC: $NAME... "
41 $DAEMON $OPTION -k graceful
42 status
43 ;;
44 restart)
45 if ! active_pidfile $PIDFILE cherokee ; then
46 echo "$NAME is not running."
47 exit 1
48 fi
49 echo -n "Restarting $DESC: $NAME... "
50 $DAEMON $OPTIONS -k restart
51 status
52 ;;
53 *)
54 echo ""
55 echo -e "\033[1mUsage:\033[0m /etc/init.d/`basename $0` [start|stop|reload|restart]"
56 echo ""
57 exit 1
58 ;;
59 esac
61 exit 0