templates:-/etc/prometheus-webhook-dingtalk/dingding.tmplwebhook:k8s:url:https://oapi.dingtalk.com/robot/send?access_token=#配置webhook地址secret:"SEC***"#生成的secretmessage:text:'{{ template "dingtalk.to.message" . }}'#需要引用的模板名 接着创建告警模板 {{ define"dingtalk.to.message"}} {...
apiVersion: v1 kind: ConfigMap metadata: name: prometheus-rules namespace: monitor labels: app: prometheus data: rules.yml: | groups: - name: docker状态-监控告警 rules: - alert: prometheus的cpu使用率大于90% expr: rate(process_cpu_seconds_total{job=~"prometheus"}[1m]) * 100 > 90 for:...
- url:'http://prometheus-webhook-dingtalk.monitor-sa:8060/dingtalk/cluster1/send'send_resolved:truekubectl apply -f alertmanager-cm.yaml
tar zxvf prometheus-webhook-dingtalk-0.3.0.linux-amd64.tar.gz cd prometheus-webhook-dingtalk-0.3.0.linux-amd64 启动钉钉报警插件: 代码语言:javascript 复制 nohup ./prometheus-webhook-dingtalk --web.listen-address="0.0.0.0:8060" --ding.profile="cluster1=https://oapi.dingtalk.com/robot/send?acce...
DockerHub:timonwong/prometheus-webhook-dingtalk Clone the repository and build manually: Usage usage: prometheus-webhook-dingtalk [<flags>] Flags: -h, --help Show context-sensitive help (also try --help-long and --help-man). --web.listen-address=:8060 The address to listen on for web int...
K8s---Prometheus+Altermanager钉钉报警 一、添加钉钉机器人 参考钉钉官方文档:https://ding-doc.dingtalk.com/doc#/serverapi2/qf2nxq 二、在k8s上部署钉钉告警deployment,这里我们引用第三方的插件。 代码语言:javascript 复制 [root@cn-hongkong webhook-dingtalk]# cat webhook-dingtalk.yamlapiVersion:apps/v1...
2、给node打标签确定下prometheus的node,标签nodetype=prometheus [root@2dot241 sy]kubectl label node 2dot239 nodetype=prometheus 因想要让数据持久化存储,所以固定了prometheus所在的node 这个参数nodeSelector:所以要给相应的node上打个标签[root@2dot239 ~]mkdir-p/data/prometheus/data&&chmod777/data/prometheus...
②、在prometheus目录下创建jmx-exporter.yaml 文件 [root@k8s01 ability_jobs]# cat prometheus/jmx-exporter.yaml --- lowercaseOutputLabelNames: true lowercaseOutputName: true rules: - pattern: 'Catalina<type=GlobalRequestProcessor, name=\"(\w+-\w+)-(\d+)\"><>(\w+):' ...
DingTalk integration for Prometheus Alertmanager. Contribute to k8stech/prometheus-webhook-dingtalk development by creating an account on GitHub.
告警采用开源项目https://github.com/timonwong/prometheus-webhook-dingtalk 实现 cd kube-prometheus/manifests/add/alert/dingtalk sh install.sh 1. 2. 同时开启企业微信、钉钉告警 告警采用开源项目https://github.com/feiyu563/PrometheusAlert 实现