Skip to content

Instantly share code, notes, and snippets.

@kml
Created June 1, 2016 11:40
Show Gist options
  • Save kml/267b9c984d5d613cb22c140191402910 to your computer and use it in GitHub Desktop.
Save kml/267b9c984d5d613cb22c140191402910 to your computer and use it in GitHub Desktop.
# This file is used by Rack-based servers to start the application.
require ::File.expand_path('../config/environment', __FILE__)
app = Rack::Builder.new do
map "/ping" do
run lambda { |_env| [200, {'Content-Type' => 'text/plain'}, ['pong']] }
end
map "/" do
run Rails.application
end
end
run app
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment