zabbix配置钉钉报警脚本

#!/bin/bash

to=$1
subject=$2
text=$3

curl 'https://oapi.dingtalk.com/robot/send?access_token=6faf4c4b090ef795a0d550354d68b6b0f82ad********5d0c6842dc6bb058c95' \
-H 'Content-Type: application/json' \
-d '
{
    
    
    "msgtype":"text",
    "text": {
    
    
        "content":"'"$text"'"
    },

    "at": {
    
    
        "atMobiles":[
            "1871506****"
        ],

        "isAtAll":false
    }
}'

猜你喜欢

转载自blog.csdn.net/qq_42906357/article/details/124381628