Sensu Plugins Meta

Build Status Gem Version

Functionality

This Sensu plugin can be used to run another plugin multiple times as one batch check.

Files

  • bin/check-meta-ruby.rb

Usage

The check-meta-ruby.rb script requires another Sensu plugin to run and a JSON array of options to run it with. The JSON can be provided either as a string:

check-meta-ruby.rb -c /opt/sensu/embedded/bin/check-http.rb \
  -j '[{"url": "http://pants.com/"}, {"url": "https://www.google.com"}]'

...or as a path to a file:

check-meta-ruby.rb -c /opt/sensu/embedded/bin/check-http.rb \
  -j /etc/sensu/http_checks.json

If a full path is not provided for the Sensu plugin file, an attempt will be made to find it relative to the check-meta-ruby.rb file.

Installation

Installation and Setup

Notes

The Ruby check makes certain assumptions about the plugin it's being asked to run:

  • It must be a child of the Sensu::Plugin::Check::CLI class
  • It must be the only Sensu check defined in the configured plugin file