periodically checks status of website and alerts (slack) chat room if response error
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib
spec
.gitignore
Gemfile
README.md
lita-ping-me.gemspec

README.md

lita-ping-me

lita-ping-me is a (slack) handler for Lita to ping a web service periodically and post to a channel if there is an error

Installation

Add lita-ping-me to your Lita instance's Gemfile:

gem "lita-ping-me"

Configuration

Required attributes

  • urls (Array) – An array of urls for lita-ping-me to periodically check
  • frequency (Integer) – How frequent to check for the service in minutes
  • channel (String) – Which (slack) channel id to post alerts to.

To get the channel ID:

 channel find channel-name

Example

Lita.configure do |config|
  config.handlers.ping_me.urls = ["http://google.com", "https://github.com"]
  config.handlers.ping_me.room = 'C03EV32P*'
  config.handlers.ping_me.frequency = 1
end

Usage

  • lita status http://google.com -> returns status of url
  • lita times http://google.com 200 -> returns last 10 times of url
  • lita any errors? -> checks currently set urls for any 500's
  • lita sleep -> stop checking for errors for 20 minutes
  • lita sleep 30 -> stop checking for errors for 30 minutes

License

MIT