global: smtp_smarthost: 'localhost:587' smtp_from: 'alerts@torrentgateway.local' route: group_by: ['alertname'] group_wait: 10s group_interval: 10s repeat_interval: 1h receiver: 'web.hook' receivers: - name: 'web.hook' webhook_configs: - url: 'http://localhost:5001/webhook' send_resolved: true - name: 'email-alerts' email_configs: - to: 'admin@torrentgateway.local' subject: 'Torrent Gateway Alert: {{ .GroupLabels.alertname }}' body: | {{ range .Alerts }} Alert: {{ .Annotations.summary }} Description: {{ .Annotations.description }} Labels: {{ range .Labels.SortedPairs }}{{ .Name }}={{ .Value }} {{ end }} {{ end }} - name: 'slack-alerts' slack_configs: - api_url: 'YOUR_SLACK_WEBHOOK_URL' channel: '#alerts' title: 'Torrent Gateway Alert' text: '{{ range .Alerts }}{{ .Annotations.summary }}{{ end }}' inhibit_rules: - source_match: severity: 'critical' target_match: severity: 'warning' equal: ['alertname', 'dev', 'instance']