diff options
-rw-r--r-- | debian/changelog | 1 | ||||
-rw-r--r-- | nagios-templates.cfg | 5 |
2 files changed, 6 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog index 6bbbd18..f75edd8 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,6 +3,7 @@ sitesummary (0.0.58) UNRELEASED; urgency=low * Ignore entries from host failing to report MAC address, and log this to syslog, to avoid getting bogus entries. * Fix brown paper back typo in collection of xfs config file. + * Provide host-notify-by-email Nagios command as well. -- Petter Reinholdtsen <pere@debian.org> Sun, 24 Jan 2010 08:43:39 +0100 diff --git a/nagios-templates.cfg b/nagios-templates.cfg index 797b56e..b38edfa 100644 --- a/nagios-templates.cfg +++ b/nagios-templates.cfg @@ -43,6 +43,11 @@ define command { command_line /bin/true } +define command { + command_name host-notify-by-email + command_line /usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTALIAS$\nState: $HOSTSTATE$ for $HOSTDURATION$\nAddress: $HOSTADDRESS$\nInfo:\n\n$HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n\nACK by: $HOSTACKAUTHOR$\nComment: $HOSTACKCOMMENT$\n" | /usr/bin/mail -s "** $NOTIFICATIONTYPE$ alert $NOTIFICATIONNUMBER$ - $HOSTALIAS$ host is $HOSTSTATE$ **" $CONTACTEMAIL$ +} + define command{ command_name notify-by-email command_line /usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nState: $SERVICESTATE$ for $SERVICEDURATION$\nAddress: $HOSTADDRESS$\n\nInfo:\n\n$SERVICEOUTPUT$\n\nDate/Time: $LONGDATETIME$\n\nACK by: $SERVICEACKAUTHOR$\nComment: $SERVICEACKCOMMENT$\n" | /usr/bin/mail -s "** $NOTIFICATIONTYPE$ alert $NOTIFICATIONNUMBER$ - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$ |