Skip to content

formorer/icinga2-slack-notification

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

slack notifications for icinga2

This is my perl implemenation of a slack service notification handler for icinga2. It was heavily inspired by https:/jjethwa/icinga2-slack-notification/blob/master/slack-service-notification.sh.

Dependencys

  • WebService::Slack::WebApi
  • Config::IniFiles
  • Switch

Installation and configuration

Drop slack-notification and slack-notification.ini into /etc/icinga2/scripts. Then get yourself an API token at http://api.slack.com/web and add into the configuration file.

You also have to insert the hostname of your icingaweb2 installation into General/WebHostname.

You can also adjust the channel used by the notification handler (General/Channel).

slack.conf contains example user/group/command/notification objects, drop it into conf.d and adapt it to your needs.

Message formatting

You can add your own emojis to the various servicestates. Just Edit Format/SERVICESTATE. See https:/iamcal/emoji-data for a list of supported emojis.

TODO

If someone really uses that, the following things would be nice:

  • make message configurable via template
  • add proper host notification
  • some error handling

About

Icinga2 notification handler for slack

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages