From e78b9363392b73790d3d47490d3107adf32e406f Mon Sep 17 00:00:00 2001 From: Abhilash Shetty Date: Thu, 5 Sep 2024 01:55:35 +0530 Subject: [PATCH] chore(alerting): changes on rules and alert config Signed-off-by: Abhilash Shetty --- .../rules/lvmLocalPV/lvmlocalpv-rules.json | 6 ++++++ deploy/charts/values.yaml | 20 +++++++++++++++++-- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/deploy/charts/rules/lvmLocalPV/lvmlocalpv-rules.json b/deploy/charts/rules/lvmLocalPV/lvmlocalpv-rules.json index 8683151..c14b26e 100644 --- a/deploy/charts/rules/lvmLocalPV/lvmlocalpv-rules.json +++ b/deploy/charts/rules/lvmLocalPV/lvmlocalpv-rules.json @@ -14,6 +14,8 @@ "expr": "lvm_vg_missing_pv_count > 0", "for": "5m", "labels": { + "service": "openebs", + "engine": "lvm-localpv", "severity": "critical" } }, @@ -28,6 +30,8 @@ "expr": "((lvm_vg_total_size_bytes - lvm_vg_free_size_bytes)/lvm_vg_total_size_bytes)*100 > 90", "for": "5m", "labels": { + "service": "openebs", + "engine": "lvm-localpv", "severity": "critical" } }, @@ -42,6 +46,8 @@ "expr": "lvm_lv_used_percent{segtype=\"thin-pool\"} > 90", "for": "5m", "labels": { + "service": "openebs", + "engine": "lvm-localpv", "severity": "critical" } } diff --git a/deploy/charts/values.yaml b/deploy/charts/values.yaml index 34a64ca..6951eb3 100644 --- a/deploy/charts/values.yaml +++ b/deploy/charts/values.yaml @@ -94,15 +94,31 @@ kube-prometheus-stack: config: global: + smtp_smarthost: 'smtp.org:587' + smtp_from: 'user@org.com' + smtp_auth_username: 'user@org.com' + smtp_auth_password: "password" resolve_timeout: 5m route: group_by: ["alertname", "job", "volName"] group_wait: 30s group_interval: 5m repeat_interval: 4h - receiver: "null" + receiver: team-X-mails + + routes: + - matchers: + - service="openebs" + receiver: openebs-email receivers: - - name: "null" + - name: 'team-X-mails' + email_configs: + - to: 'team-X+alerts@example.org' + send_resolved: true + - name: 'openebs-email' + email_configs: + - to: 'openebs-monitoring@org.com' + send_resolved: true templates: - /etc/alertmanager/config/*.tmpl