A simple CLI Pingdom-like written in ruby. Check your site's HTTP status code and notify via Slack if anything went wrong.
bundle
Copy the .env_schema
file to .env
and fill it.
cp .env_schema .env
bin/ping-my-site ping http://google.com --expected-status-code 200 --follow-location false
--expected-status-code XXX
: define the expected HTTP status code (default:200
)--follow-location true
: allow CURL to follow HTTP redirection (default: false)
bin/ping-my-site ping http://google.com --expected-status-code 200
bin/ping-my-site ping http://mysite.be --expected-status-code 301 --follow-location false --expected-redirect-url http://www.mysite.be
Something is missing in your .env
file. Compare it to .env_schema
and be sure every constant is defined.
- /bin/bash -l -c 'cd /path/to/ping-my-site/ && bundle exec bin/ping-my-site ping http://www.6x7asbl.be --expected-status-code 200 --follow-location false'
- Add proxy support (host, port, username, password)
- Add content-check support (both string and regex)
- Add description to gemspec
- Add GitHub URL to gemspec
- Add LICENCE file
- Add post_install_message to gemspec