summaryrefslogtreecommitdiff
path: root/manualPorts/bareos-filedaemon/bareos-fd
blob: 06c6c0a7d0c14cd0a0f9a2691c2d3bd4f10ca2b2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/bin/bash
#
# /etc/rc.d/bareos-fd: bareos file daemon
#

case "$1" in

  start)

    mkdir -p /run/bareos/fd
    chown bareos:bareos /run/bareos/fd
    /usr/bin/bareos-fd

  ;;

  stop)

    kill $(cat /run/bareos/fd/bareos-fd.9102.pid)

  ;;

  restart)

    "$0" stop
    "$0" start

  ;;

  *)

    echo "usage: $0 [start|stop|restart]"

  ;;

esac

# End of file