Skip to content

Instantly share code, notes, and snippets.

@thomasbiddle
Created August 3, 2013 00:17
Show Gist options
  • Save thomasbiddle/6144442 to your computer and use it in GitHub Desktop.
Save thomasbiddle/6144442 to your computer and use it in GitHub Desktop.
require 'sinatra'
require 'net/http'
get '/' do
is_up = Net::HTTP.start('play.noobonicplague.com').head('/')
code = is_up.code
if code == '200'
"It's up!"
else
"Oh shit: #{code}"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment