forked from openimsdk/open-im-server
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
lin.huang
committed
Nov 15, 2023
1 parent
d99454d
commit 4fea9e9
Showing
2 changed files
with
4 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
{{ define "email.to.html" }} | ||
{{ range .Alerts }} | ||
|
||
--------------------------------------------------------- | ||
告警程序: prometheus_alert<br> | ||
告警级别: {{ .Labels.severity }} 级<br> | ||
告警类型: {{ .Labels.alertname }}<br> | ||
故障主机: {{ .Labels.instance }}<br> | ||
故障服务: {{ .Labels.job }}<br> | ||
告警主题: {{ .Annotations.summary }}<br> | ||
触发时间: {{ .StartsAt.Format "2020-01-02 15:04:05"}} <br> | ||
|
||
---------------------------------------------------------- | ||
{{ end }} | ||
{{ end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
groups: | ||
- name: node_down | ||
- name: instance_down | ||
rules: | ||
- alert: InstanceDown | ||
expr: up == 0 | ||
for: 1m | ||
labels: | ||
user: test | ||
severity: critical | ||
annotations: | ||
summary: "Instance {{ $labels.instance }} down" | ||
description: "{{ $labels.instance }} of job {{ $labels.job }} has been down for more than 1 minutes." |