]> git.pld-linux.org Git - packages/frox.git/blob - frox.init
2a6daff329456bbb719d2357030f15b5 frox-0.6.4.tar.gz
[packages/frox.git] / frox.init
1 #!/bin/sh
2 #
3 # frox          FROX 
4 #
5 # chkconfig:    2345 90 25
6 # description:  FROX Transparent FTP proxy
7
8 # Source function library
9 . /etc/rc.d/init.d/functions
10
11 # See how we were called.
12 case "$1" in
13   start)
14         # Check if the service is already running?
15         if [ ! -f /var/lock/subsys/frox ]; then
16                 msg_starting frox
17                 daemon frox -f /etc/frox.conf
18                 RETVAL=$?
19                 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/frox
20         else
21                 msg_Already_Running frox
22                 exit 1
23         fi
24         ;;
25   stop)
26         # Stop daemons.
27         if [ -f /var/lock/subsys/frox ]; then
28                 msg_stopping frox
29                 killproc frox
30                 rm -f /var/lock/subsys/frox /var/run/frox.pid >/dev/null 2>&1
31         else
32                 msg_Not_Running frox
33                 exit 1
34         fi
35         ;;
36   status)
37         status frox
38         exit $?
39         ;;
40   restart|reload)
41         $0 stop
42         $0 start
43         ;;
44   *)
45         msg_Usage "$0 {start|stop|restart|status}"
46         exit 1
47         ;;
48 esac
49
50 exit $RETVAL
51
This page took 0.031721 seconds and 3 git commands to generate.