From d0e33ff456224ec8525a7ac41669e8fe5fd72ff1 Mon Sep 17 00:00:00 2001 From: Josef Gustafsson Date: Thu, 24 Sep 2015 14:32:24 +0200 Subject: preparing to run tests on devp --- monitor/josef_monitor.py | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) (limited to 'monitor/josef_monitor.py') diff --git a/monitor/josef_monitor.py b/monitor/josef_monitor.py index e259bd1..a49c20e 100755 --- a/monitor/josef_monitor.py +++ b/monitor/josef_monitor.py @@ -24,10 +24,8 @@ args = parser.parse_args() # Import from config file if os.path.isfile(args.config): - # moduleNames = modules = map(__import__, [args.config[:-2]]) CONFIG = modules[0] - # from monitor_conf import ctlogs, OUTPUT_DIR, INTERVAL, DEFAULT_CERT_FILE, DB_PATH, MONITORED_DOMAINS, DOMAINS_FILE else: print "Config file not found!" sys.exit() @@ -389,11 +387,7 @@ def setup_domain_monitoring(): return monitored_domains -def load_config(path): - pass - def main(args): - monitored_domains = setup_domain_monitoring() # Create logs @@ -407,8 +401,7 @@ def main(args): for log in logs: if os.path.isfile(log.savefile): log.load() - # Build what was not loaded - # try: + # Build new entries for log in logs: log.incremental_build() @@ -420,7 +413,7 @@ def main(args): log.update_roots() old_sth = log.sth - log.update_sth() # Should this be done is later checks fail? (reorder?) + log.update_sth() # Should this be done if later checks fail? (reorder?) if old_sth["timestamp"] != log.sth["timestamp"]: log.verify_progress(old_sth) log.verify_consistency(old_sth) @@ -429,7 +422,7 @@ def main(args): for md in monitored_domains: md.update() - # Normal exit oof the program + # Normal exit of the program except KeyboardInterrupt: print time.strftime('%H:%M:%S') + ' Received interrupt from user. Saving and exiting....' for log in logs: -- cgit v1.1