本文共 1311 字,大约阅读时间需要 4 分钟。
支持Zabbix的告警,使用方法见微信公众号
Zabbix告警的使用方法
wget https://raw.githubusercontent.com/OneOaaS/weixin-alert/master/weixin_linux_amd64cp weixin_linux_amd64 /etc/zabbix/alertscripts/weixinchmod 755 /etc/zabbix/alertscripts/weixinchown zabbix:zabbix /etc/zabbix/alertscripts/weixin
/etc/zabbix/alertscripts/weixin --corpid=wxee***********81aa --corpsecret=Mm0mHwI8iVsjA*JUGySxOFMIlbosoVEkWIEiw --msg="您好告警测试" --user=oneoaas --agentid=1000003返回数据:{"errcode":0,"errmsg":"ok","invaliduser":""}
./weixin_linux_amd64 --helpUsage of ./weixin_linux_amd64: -agentid string agentid -author string http://www.oneoaas.com -corpid string corpid -corpsecret string corpsecret -msg string Send Message -user string which user to send msg
Usage of weixin_linux_amd64_toparty: -agentid string agentid -author string http://www.oneoaas.com -corpid string corpid -corpsecret string corpsecret -msg string Send Message -toparty string which toparty to send msg -totag string which totag to send msg -user string which user to send msg 其中toparty,totag,user三个参数任选其一发送即可