From a89a3bb35d20e520e0cadd1da3a5d037c1bb23b6 Mon Sep 17 00:00:00 2001 From: Benjamin Date: Wed, 22 Jul 2020 20:00:46 +0800 Subject: [PATCH] Add alertmanager webhook receivers for notification manager Signed-off-by: Benjamin --- .../alertmanager/alertmanager-secret.yaml | 24 ++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/roles/ks-monitor/files/prometheus/alertmanager/alertmanager-secret.yaml b/roles/ks-monitor/files/prometheus/alertmanager/alertmanager-secret.yaml index 34836b5da..c5171137d 100644 --- a/roles/ks-monitor/files/prometheus/alertmanager/alertmanager-secret.yaml +++ b/roles/ks-monitor/files/prometheus/alertmanager/alertmanager-secret.yaml @@ -27,6 +27,17 @@ stringData: - "name": "Default" - "name": "Watchdog" - "name": "Critical" + - "name": "prometheus" + "webhook_configs": + - "url": "http://notification-manager-svc.kubesphere-monitoring-system.svc:19093/api/v2/alerts" + - "name": "event" + "webhook_configs": + - "send_resolved": false + "url": "http://notification-manager-svc.kubesphere-monitoring-system.svc:19093/api/v2/alerts" + - "name": "auditing" + "webhook_configs": + - "send_resolved": false + "url": "http://notification-manager-svc.kubesphere-monitoring-system.svc:19093/api/v2/alerts" "route": "group_by": - "namespace" @@ -42,4 +53,15 @@ stringData: - "match": "severity": "critical" "receiver": "Critical" -type: Opaque + - "match": + "alerttype": "" + "receiver": "prometheus" + - "group_interval": "30s" + "match": + "alerttype": "event" + "receiver": "event" + - "group_interval": "30s" + "match": + "alerttype": "auditing" + "receiver": "auditing" +type: Opaque \ No newline at end of file