Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Rack time app wrapped with Rack::Builder

  • Loading branch information...
commit da23f54da70657488617f4ff0fbbbc8196fa53a2 1 parent 5636dc1
José Carlos García authored
Showing with 4 additions and 1 deletion.
  1. +4 −1 rack_builder/config.ru
5 rack_builder/config.ru
View
@@ -1,2 +1,5 @@
rack_time = Proc.new { |env| [200, {"Content-Type" => "text/plain"}, ["Hello. The time is #{Time.now}"]]}
-Rack::Handler::WEBrick.run rack_time, :Port => 9292
+builder = Rack::Builder.new do
+ run rack_time
+end
+Rack::Handler::WEBrick.run builder, :Port => 9292
Please sign in to comment.
Something went wrong with that request. Please try again.