From 1c5f85253e0bf9b3ad0bee617cd531af83105cd6 Mon Sep 17 00:00:00 2001
From: Sheogorath <sheogorath@shivering-isles.com>
Date: Wed, 23 Nov 2022 14:45:08 +0100
Subject: [PATCH] fix(iot): Fix wrong comparator in monitoring metric

The "low temprature" alert should obviously check for
tempratures BELOW a threshold, not above.
---
 apps/k8s01/iot/monitoring.yaml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/apps/k8s01/iot/monitoring.yaml b/apps/k8s01/iot/monitoring.yaml
index c6a1aa859..49ba5e6e7 100644
--- a/apps/k8s01/iot/monitoring.yaml
+++ b/apps/k8s01/iot/monitoring.yaml
@@ -59,7 +59,7 @@ spec:
       annotations:
         description: The temprature of a room/sensor has dropped below 20°C over the past 6 hours.
         summary: The temprature of a room/sensor has dropped below 20°C over the past 6 hours.
-      expr: avg_over_time(shellyht_temperature_celsius[10m]) > 20
+      expr: avg_over_time(shellyht_temperature_celsius[10m]) < 20
       for: 6h
       labels:
         issue: Temprature in {{$labels.name}} is low. Turn up the heating!
-- 
GitLab