Skip to content

Zabbix 6.x does not support incoming webhooks, So this is a simple bash implementation for a daemon listening to webhook calls and then send the same to zabbix

Notifications You must be signed in to change notification settings

zaheerabbas1988/bash-webhook_listener-Zabbix

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 

Repository files navigation

bash-webhook_listener for Zabbix

To receive incoming webhook alerts in Zabbix, you need to configure the following components on the Zabbix frontend:

  1. Create a Zabbix host for the webhook listener: Go to Configuration -> Hosts. Click on "Create host" to add a new host. Provide a Hostname and an IP address or DNS name for the webhook listener. Choose a Group for the host (e.g., "Webhook Listeners"). Click on "Templates" and link the appropriate Zabbix templates for monitoring.

  2. Create a Zabbix item to receive the webhook alerts: Go to Configuration -> Hosts. Find and click on the webhook listener host you created. Click on "Items" and then "Create item". Configure the following settings: Name: Provide a name for the item (e.g., "Webhook Alert"). Type: Select "Zabbix trapper". Key: Enter a unique key (e.g., "webhook.alert"). Type of information: Choose "Text". Update interval: Set an appropriate interval for checking the item (e.g., 30 seconds). Other settings: Configure as needed. Save the item.

  3. Create a Zabbix trigger to generate alerts based on the webhook item value: Go to Configuration -> Hosts. Find and click on the webhook listener host. Click on "Triggers" and then "Create trigger". Configure the following settings: Name: Provide a name for the trigger (e.g., "Webhook Alert Trigger"). Expression: Set the expression to trigger based on the item value (e.g., {Webhook Listener:webhook.alert.strlen()}>0). Severity: Choose an appropriate severity level for the trigger. Recovery expression: Optionally, set a recovery expression if needed. Tags and dependencies: Configure as needed. Save the trigger.

Once you have configured the Zabbix host, item, and trigger, the webhook listener script will send alerts to Zabbix using the Zabbix sender. These alerts will trigger the defined Zabbix trigger, which can be used to generate notifications, escalate incidents, or perform other actions based on your Zabbix configuration.

About

Zabbix 6.x does not support incoming webhooks, So this is a simple bash implementation for a daemon listening to webhook calls and then send the same to zabbix

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%