]> git.sur5r.net Git - bacula/bacula/blob - bacula/platforms/gentoo/bacula-sd.in
Backport from Bacula Enterprise
[bacula/bacula] / bacula / platforms / gentoo / bacula-sd.in
1 #!/sbin/runscript
2 #
3 # Copyright (C) 2000-2015 Kern Sibbald
4 # License: BSD 2-Clause; see file LICENSE-FOSS
5 #
6 # bacula       This shell script takes care of starting and stopping
7 #              the bacula Storage daemon for the Gentoo release.
8 #
9 # chkconfig: 2345 90 9
10 # description: The Leading Open Source Backup Solution.
11 #
12 #  For Bacula release @VERSION@ (@DATE@) -- @DISTNAME@
13 #
14
15 start() {
16        ebegin "Starting the Bacula Storage daemon"
17        start-stop-daemon --start --quiet --exec  @sbindir@/bacula-sd -- $2 -c @sysconfdir@/bacula-sd.conf
18        eend $?
19 }
20
21 stop() {
22        ebegin "Stopping the Bacula Storage daemon"
23        start-stop-daemon --stop --quiet --exec @sbindir@/bacula-sd
24        eend $?
25 }
26
27 restart() {
28        stop
29        sleep 5
30        start
31 }