Get the App
SLTechnology News&Howtos  ›  Network Security  › 

Push zabbix alarm through nail group chat robot

Shulou Source: shulou.com Published: 2022-06-01 06:26:57 10月04日 Update

1. First, create a new dingding.sh script under the alertscripts directory on the zabbix server, as follows:

#! / bin/bash

Content=$2

Curl 'https://oapi.dingtalk.com/robot/send?access_token=XXXX'\

-H 'Content-Type: application/json'\

-d'

{"msgtype": "text"

"text": {

"content": "${Content}'"

}

}

}'

2. Test the script

Sh dingding.sh json testzabbix zabbixcontent

3. Configure nail alarm type in zabbix interface.

Nailing robot reference document address: https://open-doc.dingtalk.com/docs/doc.htm?spm=a219a.7629140.0.0.pfRNpv&treeId=257&articleId=105735&docType=1

Tags: Script machine robot content address document interface directory end type reference alarm service test configuration push Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Docker Apple MySQL NVidia Redmi