prometheus alertmanager配置

wget https://github.com/prometheus/alertmanager/releases/download/v0.15.1/alertmanager-0.15.1.linux-amd64.tar.gz

tar zxvf alertmanager-0.15.1.linux-amd64.tar.gz 

cd alertmanager-0.15.1.linux-amd64

配置文件: alertmanager.yml

global:
  resolve_timeout: 5m

route:
  group_by: ['alertname']
  group_wait: 10s
  group_interval: 10s
  repeat_interval: 1h
  receiver: 'web.hook'
receivers:
- name: 'web.hook'
  webhook_configs:
  - url: 'http://192.168.1.188:5001/'
inhibit_rules:
  - source_match:
      severity: 'critical'
    target_match:
      severity: 'warning'
    equal: ['alertname', 'dev', 'instance']

启动

 ./alertmanager --config.file=./alertmanager.yml

访问

http://127.0.0.1:9093/

你可能感兴趣的:(prometheus alertmanager配置)