diff --git a/app/terraform/alarms/proxy_http_status.py b/app/terraform/alarms/proxy_http_status.py index ebf89c3..a98d0cb 100644 --- a/app/terraform/alarms/proxy_http_status.py +++ b/app/terraform/alarms/proxy_http_status.py @@ -39,11 +39,13 @@ class AlarmProxyHTTPStatusAutomation(BaseAutomation): f"{r.status_code} {r.reason}" ) except requests.HTTPError: + alarm = get_or_create_alarm(proxy.brn, "http-status") alarm.update_state( AlarmState.CRITICAL, f"{r.status_code} {r.reason}" ) except RequestException as e: + alarm = get_or_create_alarm(proxy.brn, "http-status") alarm.update_state( AlarmState.CRITICAL, repr(e)