Class: Rack::Handler::Thin

Inherits:
Object show all
Defined in:
lib/gems/rack-0.9.1/lib/rack/handler/thin.rb

Class Method Summary collapse

Class Method Details

.run(app, options = {}) {|server| ... } ⇒ Object

Yields:

  • (server)


6
7
8
9
10
11
12
# File 'lib/gems/rack-0.9.1/lib/rack/handler/thin.rb', line 6

def self.run(app, options={})
  server = ::Thin::Server.new(options[:Host] || '0.0.0.0',
                              options[:Port] || 8080,
                              app)
  yield server if block_given?
  server.start
end