Contents of /mcore-src/trunk/mcore-tools/src/sysvinit/mcored.rc.in
Parent Directory | Revision Log
Revision 2308 -
(show annotations)
(download)
Mon Jan 20 14:13:50 2014 UTC (10 years, 8 months ago) by niro
File size: 967 byte(s)
Mon Jan 20 14:13:50 2014 UTC (10 years, 8 months ago) by niro
File size: 967 byte(s)
-updated runlevels
1 | #!/bin/bash |
2 | # $Id$ |
3 | |
4 | #%rlevels: 3:s 4:s 5:s 0:k 1:k 2:k 6:k |
5 | #%start: 90 |
6 | #%stop: 10 |
7 | |
8 | #deps |
9 | #%needs: |
10 | #%before: |
11 | #%after: |
12 | |
13 | source @@CONFDDIR@@/rc |
14 | source $rc_functions |
15 | source @@CONFDDIR@@/mcored |
16 | |
17 | case "$1" in |
18 | start) |
19 | rc_print "Starting mCore client daemon ..." |
20 | start-stop-daemon --start --exec @@SBINDIR@@/sslsvd \ |
21 | --pidfile @@RUNDIR@@/mcored.pid --background --make-pidfile \ |
22 | -- -U ${SSL_USER} -/ ${CHROOT_DIR} -Z ${SSL_CERT} -K ${SSL_KEY} \ |
23 | ${OPTS} ${LISTEN_IP} ${LISTEN_PORT} @@SBINDIR@@/mcored |
24 | evaluate_retval |
25 | |
26 | update_svcstatus $1 |
27 | splash svc_started "$(basename $0)" 0 |
28 | ;; |
29 | |
30 | stop) |
31 | rc_print "Stopping mCore client daemon ..." |
32 | start-stop-daemon --quiet --stop --pidfile @@RUNDIR@@/mcored.pid |
33 | evaluate_retval |
34 | |
35 | update_svcstatus $1 |
36 | splash svc_stopped "$(basename $0)" 0 |
37 | ;; |
38 | |
39 | restart) |
40 | $0 stop |
41 | sleep 1 |
42 | $0 start |
43 | ;; |
44 | |
45 | status) |
46 | statusproc @@SBINDIR@@/sslsvd |
47 | ;; |
48 | |
49 | *) |
50 | rc_echo "Usage: $0 {start|stop|restart|status}" |
51 | exit 1 |
52 | ;; |
53 | esac |