Send email alert when tempmon server marks a client as offline
courtesy of Cole Chaney <cole@mamajeansmarket.com>
This commit is contained in:
parent
8a1551e0f5
commit
5df3379995
3 changed files with 18 additions and 0 deletions
|
@ -44,6 +44,7 @@ class TempmonBase(object):
|
|||
probe = model.TempmonProbe(config_key='testprobe', description="Test Probe")
|
||||
client.probes.append(probe)
|
||||
return {
|
||||
'client': client,
|
||||
'probe': probe,
|
||||
'status': self.enum.TEMPMON_PROBE_STATUS[self.enum.TEMPMON_PROBE_STATUS_ERROR],
|
||||
'reading': model.TempmonReading(),
|
||||
|
@ -78,6 +79,13 @@ class tempmon_error(TempmonBase, Email):
|
|||
return data
|
||||
|
||||
|
||||
class tempmon_client_offline(TempmonBase, Email):
|
||||
"""
|
||||
Sent when a tempmon client has been marked offline.
|
||||
"""
|
||||
default_subject = "Client Offline"
|
||||
|
||||
|
||||
class tempmon_good_temp(TempmonBase, Email):
|
||||
"""
|
||||
Sent whenever a tempmon probe first takes a "good temp" reading, after
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue