grafana 最近發布了8.0 功能還是很不錯的,以下是關於8.0 報警運行的配置說明,具體使用可以參考官方文檔
docker-compose 文件
version: "2.2"
services:
grafana:
image: grafana/grafana
environment:
- "GF_FEATURE_TOGGLES_ENABLE=ngalert" # 主要是此選項,開啟特性,默認沒開啟
ports:
- "3000:3000"
prometheus:
image: prom/prometheus
volumes:
- "./prometheus.yml:/etc/prometheus/prometheus.yml"
ports:
- "9090:9090"
參考界面
參考資料
https://grafana.com/docs/grafana/latest/administration/configuration/#feature_toggles
https://grafana.com/docs/grafana/latest/alerting/unified-alerting/opt-in/