AppHealth checks the response for a specific URL on each app server. It does so by overwriting the Host header to the original hostname to trick the app server in serving the correct content.
gem install apphealth
Tested on Ruby 2.0. Compatibility with other rubies not confirmed.
AppHealth checks for a
.apphealth.yml config file in either the current directory or your home directory. Create this file on a per project basis or just put it in your home dir as a default.
The structure of the confg file needs to be as followed:
default_url: http://domain.com/foo123 servers: - server01.domain.com - server02.domain.com
default_urlwill be checked when no parameters are supplied to the command
serversis an array of servers that are requested. It can be of any size.
After creating your config file you can check the app server by running the following command:
urlis an optional url to check, if none is given it will check the
default_urlfrom the config.
For this script to work your app servers have to be directly reachable over http(s). I recommend using a VPN connection and only allowing direct access through the VPN. This way you won't expose your app servers to the whole internet directly.
- Fork it
- 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 new Pull Request
AppHealth is released under the MIT License.