|
|
@ -79,11 +79,13 @@ def query_alert_system(url): |
|
|
|
timeout=TIMEOUT |
|
|
|
timeout=TIMEOUT |
|
|
|
) |
|
|
|
) |
|
|
|
response.raise_for_status() |
|
|
|
response.raise_for_status() |
|
|
|
return response.text |
|
|
|
return response.text[:80] |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def send_alert_mail(data): |
|
|
|
def send_alert_mail(data): |
|
|
|
headers['Reply-To'] = EMAIL_RECIPIENTS |
|
|
|
headers = { |
|
|
|
|
|
|
|
'Reply-To': EMAIL_RECIPIENTS |
|
|
|
|
|
|
|
} |
|
|
|
body = '\n'.join(EMAIL_BODY) |
|
|
|
body = '\n'.join(EMAIL_BODY) |
|
|
|
pysema.send( |
|
|
|
pysema.send( |
|
|
|
EMAIL_RECIPIENTS, |
|
|
|
EMAIL_RECIPIENTS, |
|
|
|