From 0a604b77ba3a9d8c5514484e49131436ffafe787 Mon Sep 17 00:00:00 2001 From: Tobias Reisinger Date: Tue, 8 Oct 2024 17:46:14 +0200 Subject: [PATCH] Improve gatus/monitoring a bit --- playbooks/filter_plugins/gatus.py | 4 ++++ services.auto.tfvars | 8 +++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/playbooks/filter_plugins/gatus.py b/playbooks/filter_plugins/gatus.py index 99971f4..aa9ef3b 100644 --- a/playbooks/filter_plugins/gatus.py +++ b/playbooks/filter_plugins/gatus.py @@ -47,6 +47,7 @@ class FilterModule(object): default_conditions = [ "[STATUS] == any(200, 204)", + "[CERTIFICATE_EXPIRATION] > 48h" ] for service in services: @@ -79,6 +80,9 @@ class FilterModule(object): "url": url, "conditions": conditions, "alerts": self.default_alerts, + "ui": { + "hide-url": True + } } result.append(new_endpoint) diff --git a/services.auto.tfvars b/services.auto.tfvars index 536cab6..9a3dd73 100644 --- a/services.auto.tfvars +++ b/services.auto.tfvars @@ -314,7 +314,13 @@ services = { name = "postgresql" type = "hook" }] - # TODO add monitoring + monitoring = { + url = "tcp://db.serguzim.me:5432" + group = "7-support" + conditions = [ + "[CONNECTED] == true" + ] + } auth = false database = false s3 = false