GitHub Sale: sign up for any paid plan this week and pay nothing until January 1, 2009!  [ hide ]

public
Clone URL: git://github.com/defunkt/barefootexamples.git
defunkt (author)
Sun Mar 16 23:28:31 -0700 2008
commit  a4e0158e0bb0bc39121841c787d15bbcfe0a0e27
tree    ac8460a7ec9715c8c5345c1aab4abeb8e0935073
barefootexamples / 05rack.rb
100644 9 lines (8 sloc) 0.202 kb
1
2
3
4
5
6
7
8
9
class Barefoot
  def call(env)
    [ 200, 'Yes sir!', { 'Content-Type' => 'text/plain'} ]
  end
end
 
Rack::Handler::Mongrel.run(Barefoot.new, :Port => 8000) do |server|
  trap("INT") { server.stop }
end