Skip to content

Commit 33e4143

Browse files
committed
Fix script usage on Debian
1 parent 64385ee commit 33e4143

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

zabbix-zimbra/zbx_zimbra.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Zabbix script to check Zimbra services and perform service discovery.
44
# Supports Zimbra 8.6 and "two-worded" service names
55
# Author: Lorenzo Milesi <maxxer@yetopen.it>
6-
# Copyright: YetOpen S.r.l. 2014
6+
# Copytight: YetOpen S.r.l. 2015
77
# License: GPLv3
88

99
# uncomment for debug
@@ -20,18 +20,18 @@ case "$1" in
2020
exit 0;
2121
fi
2222
# error
23-
return 1;
23+
exit 1;
2424
;;
2525
discover)
2626
# Return a list of running services in JSON
2727
echo "{"
28-
echo "\t\"data\":[\n"
28+
echo -e "\t\"data\":[\n"
2929
SRVCS=$($COMMAND status | grep Running | awk '{$(NF--)=""; print}' | sed 's/^/\t{ \"{#ZIMBRASERVICE}\":\"/' | sed 's/\ $/\" },/')
3030
# Remove last comma from the sting, to make a good JSON
3131
echo $(echo $SRVCS | sed 's/,\+$//')
32-
echo "\n\t]\n"
32+
echo -e "\n\t]\n"
3333
echo "}"
34-
return 0;
34+
exit 0;
3535
;;
3636
*)
3737
# move on...

0 commit comments

Comments
 (0)