Skip to content

Alertmanager

Documentation: Sending notifications to external systems

Example receiver

Proxy & Alertmanager

Warning

Alertmanager do not pickup global proxy settings.

alertmanager.yaml

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
"global":
  "resolve_timeout": "5m"
  slack_api_url: https://hooks.slack.com/services/xxxx/xxxx/xxxxx
"receivers":
  - name: slack
    slack_configs:
    - channel: '#ops'
      http_config:
        proxy_url: http://192.168.51.1:8888

"route":
  "group_by":
  - "job"
  "group_interval": "5m"
  "group_wait": "30s"
  "receiver": "slack"
  "repeat_interval": "12h"
  "routes":
    - receiver: slack
      match:
        alertname: Watchdog

Apply config:

1
2
3
4
oc -n openshift-monitoring create secret generic alertmanager-main \
   --from-file=alertmanager.yaml=alertmanager.yaml \
   --dry-run -o=yaml |  oc -n openshift-monitoring replace secret \
   --filename=-

Last update: June 18, 2021
Back to top