{"id":18906493,"url":"https://github.com/claranet/zabbix-sqs","last_synced_at":"2026-05-02T10:39:35.852Z","repository":{"id":64307605,"uuid":"122960283","full_name":"claranet/zabbix-sqs","owner":"claranet","description":"Forward Zabbix alerts to SQS queue","archived":false,"fork":false,"pushed_at":"2018-04-10T09:46:08.000Z","size":2302,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":8,"default_branch":"master","last_synced_at":"2026-05-02T10:39:35.692Z","etag":null,"topics":["alerting","aws","sqs","zabbix"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/claranet.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-02-26T11:29:06.000Z","updated_at":"2023-11-16T14:04:59.000Z","dependencies_parsed_at":"2023-01-15T11:00:43.931Z","dependency_job_id":null,"html_url":"https://github.com/claranet/zabbix-sqs","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/claranet/zabbix-sqs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claranet%2Fzabbix-sqs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claranet%2Fzabbix-sqs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claranet%2Fzabbix-sqs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claranet%2Fzabbix-sqs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/claranet","download_url":"https://codeload.github.com/claranet/zabbix-sqs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claranet%2Fzabbix-sqs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32531742,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-02T01:12:54.858Z","status":"online","status_checked_at":"2026-05-02T02:00:05.923Z","response_time":132,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["alerting","aws","sqs","zabbix"],"created_at":"2024-11-08T09:16:29.646Z","updated_at":"2026-05-02T10:39:35.818Z","avatar_url":"https://github.com/claranet.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"Zabbix-SQS alertscript\n======================\n\nForward Zabbix alerts to SQS queue by using a custom Zabbix [alertscript](https://www.zabbix.com/documentation/3.4/manual/config/notifications/media/script).\n\nScript installation\n-------------------\n\nSimply decompress archive found in [releases section](https://github.com/claranet/zabbix-sqs/releases):\n\n    $ bunzip2 `zabbix-sqs.bz2`\n\nThen mv `zabbix-sqs` bonary and its json config file on zabbix server to the `AlertScriptsPath`\ndirectory which can be found in the `/etc/zabbix/zabbix_server.conf` configuration file:\n\n    $ grep -e '^AlertScriptsPath' /etc/zabbix/zabbix_server.conf\n    AlertScriptsPath=/path/to/zabbix/alertscripts\n    $ mv `zabbix-sqs` /path/to/zabbix/alertscripts\n    $ mv `zabbix-sqs.json` /path/to/zabbix/alertscripts\n\nBe sure zabbix user is able to execute `zabbix-sqs` file\n\nZabbix configuration\n--------------------\n\nTo forward Zabbix events to SQS a new media script needs to be created\nand associated with a user. Follow the steps below as a Zabbix Admin user...\n\n1/ Create a new media type [Admininstration \u003e Media Types \u003e Create Media Type]\n\n```\nName: SQS\nType: Script\nScript name: zabbix-sqs\nScript parameters:\n    1st: {ALERT.MESSAGE}\n    2nd: Nothing (remove field)\n    3nd: Nothing (remove field)\nEnabled: [x]\n```\n\n2/ Modify the Media for the Admin user or create a new one if you prefer filter permissions [Administration \u003e Users]\n\n```\nType: SQS\nSend to: sqs-queue\nWhen active: 1-7,00:00-24:00\nUse if severity: (all)\nStatus: Enabled\n```\n\n3/ Configure Action [Configuration \u003e Actions \u003e Create Action \u003e Action]\n\n```\nName: zabbix-sqs\n```\n```\nDefault subject: Nothing (empty field)\n```\n```\n{\"ID\":{TRIGGER.ID},\"Name\":\"{TRIGGER.NAME}\",\"Status\":\"{TRIGGER.STATUS}\",\"Group\":\"{TRIGGER.HOSTGROUP.NAME}\",\"Severity\":\"{TRIGGER.SEVERITY}\",\"Hostname\":\"{HOSTNAME}\",\"IP\":\"{IPADDRESS}\",\"Items\":[{\"Name\":\"{ITEM.NAME1}\",\"Value\":\"{ITEM.VALUE1}\"},{\"Name\":\"{ITEM.NAME2}\",\"Value\":\"{ITEM.VALUE2}\"},{\"Name\":\"{ITEM.NAME3}\",\"Value\":\"{ITEM.VALUE3}\"},{\"Name\":\"{ITEM.NAME4}\",\"Value\":\"{ITEM.VALUE4}\"},{\"Name\":\"{ITEM.NAME5}\",\"Value\":\"{ITEM.VALUE5}\"},{\"Name\":\"{ITEM.NAME6}\",\"Value\":\"{ITEM.VALUE6}\"},{\"Name\":\"{ITEM.NAME7}\",\"Value\":\"{ITEM.VALUE7}\"},{\"Name\":\"{ITEM.NAME8}\",\"Value\":\"{ITEM.VALUE8}\"},{\"Name\":\"{ITEM.NAME9}\",\"Value\":\"{ITEM.VALUE9}\"}]}\n```\n\nRECOVERY\n```\nDefault subject: Nothing (empty field)\n```\n```\n{\"ID\":{TRIGGER.ID},\"Name\":\"{TRIGGER.NAME}\",\"Status\":\"{TRIGGER.STATUS}\",\"Group\":\"{TRIGGER.HOSTGROUP.NAME}\",\"Severity\":\"{TRIGGER.SEVERITY}\",\"Hostname\":\"{HOSTNAME}\",\"IP\":\"{IPADDRESS}\",\"Items\":[{\"Name\":\"{ITEM.NAME1}\",\"Value\":\"{ITEM.VALUE1}\"},{\"Name\":\"{ITEM.NAME2}\",\"Value\":\"{ITEM.VALUE2}\"},{\"Name\":\"{ITEM.NAME3}\",\"Value\":\"{ITEM.VALUE3}\"},{\"Name\":\"{ITEM.NAME4}\",\"Value\":\"{ITEM.VALUE4}\"},{\"Name\":\"{ITEM.NAME5}\",\"Value\":\"{ITEM.VALUE5}\"},{\"Name\":\"{ITEM.NAME6}\",\"Value\":\"{ITEM.VALUE6}\"},{\"Name\":\"{ITEM.NAME7}\",\"Value\":\"{ITEM.VALUE7}\"},{\"Name\":\"{ITEM.NAME8}\",\"Value\":\"{ITEM.VALUE8}\"},{\"Name\":\"{ITEM.NAME9}\",\"Value\":\"{ITEM.VALUE9}\"}]}\n```\n\nhttps://www.zabbix.com/documentation/3.2/manual/appendix/macros/supported_by_location\n\nTo send OK events ...\n\n````\nRecovery message: [check]\nEnabled [check]\n````\n\nAt the Conditions tab, to only forward PROBLEM and OK events ...\n\n```\n(A)\tMaintenance status not in \"maintenance\"\n(B)\tTrigger value = \"PROBLEM\"\n```\n\nTo forward PROBLEM, ACKNOWLEDGED, OK events ...\n\n```\n(A)\tMaintenance status not in \"maintenance\"\n```\n\nFinally, add an operation:\n\n```\nSend to Users: Admin (or previously created user)\nSend only to: zabbix-sqs\n```\n\nScript configuration\n--------------------\n\nThe configuration file `zabbix-sqs.json` should be located next to the script in alertscripts directory\n\n**Configuration parameters**\n\nThe following parameters should be configured :\n\n  * QueueURL\n  * Region\n  * AccessKeyID\n  * SecretAccessKey\n\nin `zabbix-sqs.json` file next to the binaray `zabbix-sqs`\n\nHere is a [sample configuration file](zabbix-sqs.json.sample)\n\nAWS configuration\n-----------------\n\nThe following resources should be created :\n\n  * IAM user\n  * IAM policy\n  * SQS Queue\n\nFirst, create the queue and configure it according your needs. Get the SQS `QueueURL` and its `Region` to set it in the configuration file.\n\nThen, create an IAM user for zabbix and generate credentials. Get `AccessKeyID` and `SecretAccessKey` to set it in the configuration file.\n\nFinally, add an inline IAM policy to the previously created user to grant it SQS privileges. Taking example from [the sample configuration file](zabbix-sqs.json.sample) :\n\n```\n{\n    \"Version\": \"2012-10-17\",\n    \"Statement\": [\n        {\n            \"Effect\": \"Allow\",\n            \"Action\": \"sqs:ListQueues\",\n            \"Resource\": \"*\",\n            \"Condition\": {\n                \"IpAddress\": {\n                    \"aws:SourceIp\": \"#ZABBIX_SERVER_IP#\"\n                }\n            }\n        },\n        {\n            \"Effect\": \"Allow\",\n            \"Action\": \"sqs:*\",\n            \"Resource\": \"https://sqs.ap-northeast-1.amazonaws.com/42133769/my-queue\",\n            \"Condition\": {\n                \"IpAddress\": {\n                    \"aws:SourceIp\": \"#ZABBIX_SERVER_IP#\"\n                }\n            }\n        }\n    ]\n}\n```\n\nTroubleshooting\n---------------\n\nSee the [PagerDuty guide](http://www.pagerduty.com/docs/guides/zabbix-integration-guide/)\nto configuring Zabbix integrations for an example installation with\nscreenshots.\n\nReferences\n----------\n\n  * [Zabbix Custom Alert Scripts](https://www.zabbix.com/documentation/3.4/manual/config/notifications/media/script)\n  * [Zabbix Custom User Macros](https://www.zabbix.com/documentation/3.4/manual/config/macros/usermacros)\n\nLicense\n-------\n\nCopyright (c) 2018 Claranet. Available under the MIT License.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclaranet%2Fzabbix-sqs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fclaranet%2Fzabbix-sqs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclaranet%2Fzabbix-sqs/lists"}