Vaimo Messages Handler plugin for Sensu

Functionality

Files

  • bin/send-message.rb

Usage

VaimoMessages

Create a json config file with your web_hook, auth_token, recipient and from.

{
  "messages": {
    "web_hook": "http://to.web.hook.urli/send",
    "auth_token": "XXXXXXXXXXXXXXXXXXXXXXXXX",
    "recipient": "group",
    "from": "Sensu"
  }
}

Set your check to use the handler and define the playsms recipients.

{
  "checks": {
    "check-disk-usage": {
      "command": "check-disk-usage.rb -w :::disk.warning|80::: -c :::disk.critical|90:::",
      "subscribers": [
        "production"
      ],
      "handlers": [
        "vaimo-messages"
      ],
      "interval": 60
    }
  }
}

Installation

Installation and Setup

Notes

Development

When using ubuntu for development and testing then be sure to install ruby-dev

$ sudo apt-get install ruby-dev
$ sudo gem install bundle

To work on the plugin, clone this repository out, and use Bundler to get the dependencies:

$ bundle

Once you have the dependencies, verify the unit tests pass with rake:

$ bundle exec rake

Build the plugin with

rake build