X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;f=dsa-nagios-nrpe-config%2Fdebian%2Fpostinst;h=0749532da5516fa167ca51a6cf105f1b17665466;hb=682fa1a77ef21e4b1ccd5ee3cf9a1759690d80df;hp=3f0c530f9beaee5da0b128aec1f336df0cc8487b;hpb=59a4b83f685dfee01f3f39af9ec0acfd509763a1;p=mirror%2Fdsa-nagios.git diff --git a/dsa-nagios-nrpe-config/debian/postinst b/dsa-nagios-nrpe-config/debian/postinst index 3f0c530..0749532 100644 --- a/dsa-nagios-nrpe-config/debian/postinst +++ b/dsa-nagios-nrpe-config/debian/postinst @@ -47,6 +47,15 @@ if [ -e /etc/sudoers ] ; then fi fi +if [ -e /etc/sudoers ] ; then + if ! grep '^nagios.*/usr/sbin/samhain' /etc/sudoers > /dev/null; then + echo + echo 'WARNIG: Add this line to sudoers:' + echo 'nagios ALL=(ALL) NOPASSWD: /usr/sbin/samhain -t check --foreground -p err -s none -l none -m none' + echo + fi +fi + if [ -e /usr/sbin/hpacucli ] && [ -e /dev/cciss/c0d0 ] ; then if ! grep '^nagios.*hpacucli' /etc/sudoers > /dev/null; then echo