check_monitor_bot: remove debug print

This commit is contained in:
Cyberes 2023-05-30 21:50:54 -06:00
parent 4878b668c4
commit 0ddcbdc382
1 changed files with 2 additions and 4 deletions

View File

@ -58,7 +58,6 @@ def main():
m = re.match(r'<span class="tooltip">\s*Send: (.*?)\s*<br\/>\s*Receive: (.*?)\s*<\/span>', str(item))
if m:
domain = item.parent.parent.find('span', {'class': 'domain'}).text
print(domain)
s = ms_to_s(m.group(1))
r = ms_to_s(m.group(2))
data[domain] = {
@ -108,8 +107,7 @@ def main():
if len(crit_failed_hosts) / len(data.keys()) >= (args.crit_percent / 100):
# CRIT takes precedence
exit_code = nagios.CRITICAL
print(
f'CRITICAL: {make_percent(len(crit_failed_hosts) / len(data.keys()))}% of hosts are marked as critical.')
print(f'CRITICAL: {make_percent(len(crit_failed_hosts) / len(data.keys()))}% of hosts are marked as critical.')
elif len(warn_failed_hosts) / len(data.keys()) >= (args.warn_percent / 100):
exit_code = nagios.WARNING
print(f'WARN: {make_percent(len(warn_failed_hosts) / len(data.keys()))}% of hosts are marked as warn.')