Fix install doc (sudo no needs)
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful

This commit is contained in:
Benjamin Renard 2024-01-22 01:56:58 +01:00
parent f9e3e55872
commit 8c8f1a2a46

View file

@ -9,9 +9,7 @@ apt install git python3-requests
git clone https://gitea.zionetrix.net/bn8/check_woodpecker_upgrade.git /usr/local/src/check_woodpecker_upgrade git clone https://gitea.zionetrix.net/bn8/check_woodpecker_upgrade.git /usr/local/src/check_woodpecker_upgrade
mkdir -p /usr/local/lib/nagios/plugins mkdir -p /usr/local/lib/nagios/plugins
ln -s /usr/local/src/check_woodpecker_upgrade/check_woodpecker_upgrade /usr/local/lib/nagios/plugins/ ln -s /usr/local/src/check_woodpecker_upgrade/check_woodpecker_upgrade /usr/local/lib/nagios/plugins/
echo "nagios ALL=NOPASSWD: /usr/local/lib/nagios/plugins/check_woodpecker_upgrade" > /etc/sudoers.d/nagios-woodpecker echo "command[check_woodpecker_upgrade]=/usr/local/lib/nagios/plugins/check_woodpecker_upgrade" > /etc/nagios/nrpe.d/woodpecker.cfg
chmod 0400 /etc/sudoers.d/nagios-woodpecker
echo "command[check_woodpecker_upgrade]=sudo /usr/local/lib/nagios/plugins/check_woodpecker_upgrade" > /etc/nagios/nrpe.d/woodpecker.cfg
service nagios-nrpe-server reload service nagios-nrpe-server reload
``` ```