aboutsummaryrefslogtreecommitdiffstats
path: root/kubernetes/namespaces/monitoring/alerts/alertmanager.yaml
blob: bef166adbc46bb3452d27addb5cce41049764e12 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
route:
  group_by: ['alertname', 'cluster', 'service']

  group_wait: 15s

  group_interval: 1m

  receiver: devops-team

receivers:
- name: devops-team
  slack_configs:
  - api_url_file: "/opt/pydis/alertmanager/webhooks/DEVOPS_HOOK"
    send_resolved: true
    title: '{{ if eq .Status "firing" }}[FIRING]{{ else }}[RESOLVED]{{ end }}'
    text: |
      {{ if eq .Status "firing" }}{{ range .Alerts }}
      **{{ .Annotations.summary }}:**
      {{ .Annotations.description }} [(Link)]({{.GeneratorURL}})

      {{ end }}{{ else }}Alert has resolved.{{ end }}
    fields:
    - title: Alert
      value: "{{ .GroupLabels.alertname }}"