Skip to content

Instantly share code, notes, and snippets.

View devdazed's full-sized avatar

Russ Bradberry devdazed

View GitHub Profile
@devdazed
devdazed / gist:2481257
Created April 24, 2012 16:34 — forked from elubow/gist:2008708
Nagios Passive Check
#foobar
# Send the passive service check back to Nagios
logger.debug("Constructing the Nagios result string")
nag_message = config.get('nagios','message')
nag_status = 0
logger.info("Passive check result sent to Nagios")
except Exception, e:
nag_status = 2
nag_message = "%s" % (e)