We have setup Prometheus in a kubernetes cluster using PrometheusOperator. We are trying to configure AlertManager using the AlertManagerConfig custom resource. We tried creating an alert route which maps to a webhook receiver and then triggering a test alert. The alert seems to be caught by AlertManager but it is not being forwarded to the webhook endpoint. AlertManager pod logs are also not printing any logs regarding notifications being send to the receivers for an alert. Sharing the test config below:
apiVersion: monitoring.coreos.com/v1alpha1
kind: AlertmanagerConfig
metadata:
name: discord-config
spec:
receivers:
- name: discord
webhookConfigs:
- url: '<webhook-url>'
sendResolved: true
route:
groupBy: ['job']
groupWait: 15s
groupInterval: 15s
repeatInterval: 15s
receiver: 'discord'
---
apiVersion: monitoring.coreos.com/v1
kind: PrometheusRule
metadata:
name: test-rules
spec:
groups:
- name: test-rule-group
rules:
- alert: TestAlert
expr: vector(1)
labels:
severity: medium
annotations:
description: "This is a reciever test for webhook alert"
summary: "This is a dummy summary"
Is there anything else that needs to be taken care of for the receivers to start receiving alerts?