Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
HTTP Terminator and Dumper
require 'webrick'
server = WEBrick::HTTPServer.new :Port => 8000
server.mount_proc '/' do |req, res|
puts req.inspect
res.body = nil
end
trap 'INT' do server.shutdown end
server.start
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment