aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ritter <tom@ritter.vg>2017-04-03 01:18:29 -0400
committerTom Ritter <tom@ritter.vg>2017-04-03 01:18:29 -0400
commit6371a93650e74d6d4518890230eeeb5ffa7b660e (patch)
treeab625d4a3d18306cbee794a2af223e079435173b
parentfff94ecb1da0b3490adc4b8bc2e2fa590aa8aa80 (diff)
Add 5 and 10 minute intervals and fix bwauth last scanner check
-rwxr-xr-xjobs/JobBase.py2
-rwxr-xr-xsamplejobs/BWAuthChecker.py1
2 files changed, 3 insertions, 0 deletions
diff --git a/jobs/JobBase.py b/jobs/JobBase.py
index 4ac1f0d..c5be180 100755
--- a/jobs/JobBase.py
+++ b/jobs/JobBase.py
@@ -25,6 +25,8 @@ class JobFailureNotificationFrequency:
class JobFailureCountMinimumBeforeNotification:
ONE = 1
TWO = 2
+ FIVE = 5
+ TEN = 10
class JobBase(object):
def __init__(self, config, *args):
diff --git a/samplejobs/BWAuthChecker.py b/samplejobs/BWAuthChecker.py
index ee0113a..618075e 100755
--- a/samplejobs/BWAuthChecker.py
+++ b/samplejobs/BWAuthChecker.py
@@ -74,6 +74,7 @@ class BWAuthChecker(JobBase.JobBase):
elif l.strip():
last_measured = re.match("NOTICE\[[^\s]+ ([0-9a-zA-Z: ]+)\]", l).groups(0)[0]
last_measured = datetime.datetime.strptime(last_measured, "%b %d %H:%M:%S %Y")
+ measurement_times[this_scanner] = last_measured
for t in measurement_times:
if measurement_times[t] + datetime.timedelta(days=6) < datetime.datetime.now():