diff options
Diffstat (limited to 'actionpack/lib/action_dispatch/vendor/rack-1.0/rack/handler/thin.rb')
-rw-r--r-- | actionpack/lib/action_dispatch/vendor/rack-1.0/rack/handler/thin.rb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/actionpack/lib/action_dispatch/vendor/rack-1.0/rack/handler/thin.rb b/actionpack/lib/action_dispatch/vendor/rack-1.0/rack/handler/thin.rb new file mode 100644 index 0000000000..3d4fedff75 --- /dev/null +++ b/actionpack/lib/action_dispatch/vendor/rack-1.0/rack/handler/thin.rb @@ -0,0 +1,18 @@ +require "thin" +require "rack/content_length" +require "rack/chunked" + +module Rack + module Handler + class Thin + def self.run(app, options={}) + app = Rack::Chunked.new(Rack::ContentLength.new(app)) + server = ::Thin::Server.new(options[:Host] || '0.0.0.0', + options[:Port] || 8080, + app) + yield server if block_given? + server.start + end + end + end +end |