AppStatus
Add JSON formatter status report for Rails / Sinatra app:
{
"PostgreSQL": "OK",
"Redis": "Down",
"Sidekiq": "Down",
"env": "staging"
}
Installation
Add this line to your application's Gemfile:
gem 'app-status'
And then execute:
$ bundle
Or install it yourself as:
$ gem install app-status
Usage
Rails
in config/routes.rb
add following line:
mount AppStatus::App.new => '/status'
Sinatra
in config.ru
add following:
require 'your_sinatra_app'
require 'app_status/app'
run Rack::URLMap.new('/' => YourSinatraApp.new, '/status' => AppStatus::App.new)
Contributing
- Fork it ( https://github.com/[my-github-username]/app_status/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request