Lines 5-14
Link Here
|
5 |
# Required-Stop: $remote_fs |
5 |
# Required-Stop: $remote_fs |
6 |
# Default-Start: 2 3 4 5 |
6 |
# Default-Start: 2 3 4 5 |
7 |
# Default-Stop: 0 1 6 |
7 |
# Default-Stop: 0 1 6 |
8 |
# Short-Description: Start Zebra server for each Koha instance |
8 |
# Short-Description: Start required services for each Koha instance |
9 |
# Description: For each enabled Koha instance on this host, |
9 |
# Description: For each enabled Koha instance on this host, |
10 |
# as listed by "koha-list --enabled", start a Zebra |
10 |
# start the required services (Zebra, SIP, Indexer and Plack) |
11 |
# server (using koha-start-zebra). |
|
|
12 |
### END INIT INFO |
11 |
### END INIT INFO |
13 |
|
12 |
|
14 |
# Author: Lars Wirzenius <lars@catalyst.net.nz> |
13 |
# Author: Lars Wirzenius <lars@catalyst.net.nz> |
Lines 22-28
NAME="koha-common"
Link Here
|
22 |
SCRIPTNAME=/etc/init.d/$NAME |
21 |
SCRIPTNAME=/etc/init.d/$NAME |
23 |
|
22 |
|
24 |
# Exit if the package is not installed |
23 |
# Exit if the package is not installed |
25 |
[ -x /usr/sbin/koha-start-zebra ] || exit 0 |
24 |
[ -x /usr/sbin/koha-zebra ] || exit 0 |
26 |
|
25 |
|
27 |
# Read configuration variable file if it is present |
26 |
# Read configuration variable file if it is present |
28 |
if [ -r /etc/default/$NAME ]; then |
27 |
if [ -r /etc/default/$NAME ]; then |
Lines 55-61
do_start()
Link Here
|
55 |
{ |
54 |
{ |
56 |
# We insure all required directories exist, including disabled ones. |
55 |
# We insure all required directories exist, including disabled ones. |
57 |
koha-create-dirs $(koha-list) |
56 |
koha-create-dirs $(koha-list) |
58 |
koha-start-zebra $(koha-list --enabled) |
57 |
koha-zebra --start $(koha-list --enabled) |
59 |
koha-start-sip $(koha-list --enabled) |
58 |
koha-start-sip $(koha-list --enabled) |
60 |
koha-plack --start $(koha-list --enabled --plack) |
59 |
koha-plack --start $(koha-list --enabled --plack) |
61 |
|
60 |
|
Lines 70-76
do_start()
Link Here
|
70 |
do_stop() |
69 |
do_stop() |
71 |
{ |
70 |
{ |
72 |
# We stop everything, including disabled ones. |
71 |
# We stop everything, including disabled ones. |
73 |
koha-stop-zebra $(koha-list) || true |
72 |
koha-zebra --stop $(koha-list) || true |
74 |
koha-stop-sip $(koha-list) || true |
73 |
koha-stop-sip $(koha-list) || true |
75 |
koha-plack --stop --quiet $(koha-list --enabled --plack) |
74 |
koha-plack --stop --quiet $(koha-list --enabled --plack) |
76 |
|
75 |
|
Lines 83-89
do_stop()
Link Here
|
83 |
# Function that sends a SIGHUP to the daemon/service |
82 |
# Function that sends a SIGHUP to the daemon/service |
84 |
# |
83 |
# |
85 |
do_reload() { |
84 |
do_reload() { |
86 |
koha-restart-zebra $(koha-list --enabled) |
85 |
koha-zebra --restart $(koha-list --enabled) |
87 |
koha-stop-sip $(koha-list) || true |
86 |
koha-stop-sip $(koha-list) || true |
88 |
koha-start-sip $(koha-list --enabled) |
87 |
koha-start-sip $(koha-list --enabled) |
89 |
koha-plack --restart --quiet $(koha-list --enabled --plack) |
88 |
koha-plack --restart --quiet $(koha-list --enabled --plack) |