Last active
October 13, 2018 16:22
-
-
Save lfv89/73266a2e839d4c29b963e8479b50bd9a to your computer and use it in GitHub Desktop.
hello world with webrick
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'webrick' | |
server = WEBrick::HTTPServer.new(:Port => 3000) | |
server.mount_proc '/' do |req, res| | |
res.body = 'Hello, World!' | |
end | |
server.start |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment