nagios-nrpe: add brackets in check grep
All checks were successful
Ansible Lint |Total|New|Outstanding|Fixed|Trend
|:-:|:-:|:-:|:-:|:-:
|2597|2|2595|2|:-1:
Reference build: <a href="https://jenkins.evolix.org/job/gitea/job/ansible-roles/job/unstable/303//ansiblelint">Evolix » ansible-roles » unstable #303</a>
gitea/ansible-roles/pipeline/head This commit looks good
All checks were successful
Ansible Lint |Total|New|Outstanding|Fixed|Trend
|:-:|:-:|:-:|:-:|:-:
|2597|2|2595|2|:-1:
Reference build: <a href="https://jenkins.evolix.org/job/gitea/job/ansible-roles/job/unstable/303//ansiblelint">Evolix » ansible-roles » unstable #303</a>
gitea/ansible-roles/pipeline/head This commit looks good
This commit is contained in:
parent
b6886384b9
commit
c2e27d025c
|
@ -6,7 +6,7 @@ if ! test -f /usr/lib/nagios/plugins/check_nrpe; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -r /etc/nagios/nrpe.d/evolix.cfg ]; then
|
if [ -r /etc/nagios/nrpe.d/evolix.cfg ]; then
|
||||||
command=$(grep "check_$1" /etc/nagios/nrpe.d/evolix.cfg | grep -v '^[[:blank:]]*#' | tail -n1 | cut -d'=' -f2-)
|
command=$(grep "\[check_$1\]" /etc/nagios/nrpe.d/evolix.cfg | grep -v '^[[:blank:]]*#' | tail -n1 | cut -d'=' -f2-)
|
||||||
echo "Command:"
|
echo "Command:"
|
||||||
echo " $command"
|
echo " $command"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue