1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-22 02:51:03 +00:00

plugin ipset: use "set -eu"

This commit is contained in:
Lars Kruse 2018-04-18 04:05:06 +02:00
parent 919991eef3
commit 4b9fcc0bcc

View file

@ -45,13 +45,15 @@ GPLv2
=cut =cut
set -eu
get_ipset_list() { get_ipset_list() {
ipset list -n ipset list -n
} }
if [ "$1" = "autoconf" ]; then if [ "${1:-}" = "autoconf" ]; then
if [ -e /sbin/ipset ] || [ -n "$(which ipset)" ]; then if [ -e /sbin/ipset ] || [ -n "$(which ipset)" ]; then
echo 'yes' echo 'yes'
else else
@ -60,7 +62,7 @@ if [ "$1" = "autoconf" ]; then
exit 0 exit 0
fi fi
if [ "$1" = "config" ]; then if [ "${1:-}" = "config" ]; then
echo graph_title Netfilter IPSets echo graph_title Netfilter IPSets
echo graph_category network echo graph_category network
echo graph_vlabel Members echo graph_vlabel Members