Skip to content

Instantly share code, notes, and snippets.

@edvakf
Last active April 28, 2016 02:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save edvakf/14a95e731c1b7a499ac2523d5a5d9438 to your computer and use it in GitHub Desktop.
Save edvakf/14a95e731c1b7a499ac2523d5a5d9438 to your computer and use it in GitHub Desktop.
$ mkdir rack-test
$ cd rack-test
$ vi Gemfile
$ vi config.ru
$ vi unicorn_config.rb
$ bundle install --path=.bundle
$ bundle exec unicorn -c ./unicorn_config.rb
class Hello
def call(env)
[ 200,
{ 'Content-Type' => 'text/plain' },
[env.inspect]
]
end
end
run Hello.new
source 'https://rubygems.org'
gem 'rack'
gem 'unicorn'
worker_processes 1
listen 8000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment