Magellan Linux

Annotation of /trunk/cvsd/cvsd.rc

Parent Directory Parent Directory | Revision Log Revision Log


Revision 964 - (hide annotations) (download)
Sun Dec 27 16:51:31 2009 UTC (14 years, 10 months ago) by niro
File size: 769 byte(s)
-new init layout

1 niro 144 #!/bin/bash
2    
3     #%rlevels: 0:k 1:k 2:k 3:s 4:k 5:s 6:k
4     #%start: 33
5     #%stop: 27
6    
7     #deps
8     #%needs:
9     #%before:
10     #%after:
11    
12 niro 964 source /etc/conf.d/rc
13 niro 144 source $rc_functions
14    
15     case "$1" in
16     start)
17     echo -e ${COLOREDSTAR}"Starting cvsd pserver daemon ..."
18     start-stop-daemon --start --quiet --background \
19     --exec /usr/sbin/cvsd
20     evaluate_retval
21    
22     update_svcstatus $1
23     splash svc_started "$(basename $0)" 0
24     ;;
25    
26     stop)
27     echo -e ${COLOREDSTAR}"Stopping cvsd pserver daemon ..."
28     start-stop-daemon --stop --quiet \
29     --pidfile /var/run/cvsd.pid
30     evaluate_retval
31    
32     update_svcstatus $1
33     splash svc_stopped "$(basename $0)" 0
34     ;;
35    
36     restart)
37     $0 stop
38     sleep 1
39     $0 start
40     ;;
41    
42     status)
43 niro 440 statusproc cvsd
44 niro 144 ;;
45    
46     *)
47     echo "Usage: $0 {start|stop|restart|status}"
48     exit 1
49     ;;
50     esac