]>
Commit | Line | Data |
---|---|---|
c0b229ae SS |
1 | #!/bin/sh |
2 | ######################################################################## | |
3 | # Begin $rc_base/init.d/vdradmind | |
4 | # | |
5 | # Description : This is a script that starts vdradmind as deamon | |
6 | # | |
7 | # Authors : Arne Fitzenreiter (arne@ipfire.org) | |
8 | # | |
9 | # Version : 01.00 | |
10 | # | |
11 | # Notes : | |
12 | # | |
13 | ######################################################################## | |
14 | ||
15 | . /etc/sysconfig/rc | |
16 | . ${rc_functions} | |
17 | ||
18 | case "${1}" in | |
19 | start) | |
20 | boot_mesg "Starting VDR Webadministration Tool..." | |
21 | if [ "$(ps -A | grep vdradmind)" != "" ]; then | |
22 | boot_mesg "Error! Already running!" | |
23 | echo_failure | |
24 | exit 1; | |
25 | fi | |
26 | loadproc /opt/vdradmin/vdradmind.pl | |
27 | ;; | |
28 | ||
29 | stop) | |
30 | boot_mesg "Stopping VDR Webadministration Tool..." | |
31 | killproc /usr/bin/vdradmind | |
32 | ;; | |
33 | ||
34 | restart) | |
35 | ${0} stop | |
36 | sleep 1 | |
37 | ${0} start | |
38 | ;; | |
39 | ||
40 | status) | |
41 | statusproc /usr/bin/vdradmind | |
42 | ;; | |
43 | ||
44 | *) | |
45 | echo "Usage: ${0} {start|stop|restart|status}" | |
46 | exit 1 | |
47 | ;; | |
48 | esac | |
49 | ||
50 | # End $rc_base/init.d/vdr |