无法在生产中运行Unicorn

时间:2016-05-27 09:50:58

标签: ruby-on-rails unicorn

尝试以root身份运行Unicorn:sudo /usr/local/bin/unicorn -E production -c config/unicorn.rb但获取rack not available, functionality reduced -- rack and Rack::Builder must be available for processing config.ru

如果我sudo bundle exec /usr/local/bin/unicorn [...]我没有得到回复。

Unicorn在我的Gemfile中,我sudo gem install unicorn

我正在使用Ruby 2.2.4p230。这是版本不兼容吗?

配置/ unicorn.rb

user "myapp", "wheel"

working_directory "/home/www/myapp"
pid "/home/www/myapp/tmp/unicorn.pid"
stderr_path "/home/www/myapp/log/unicorn.log"
stdout_path "/home/www/myapp/log/unicorn.log"

listen "/home/www/myapp/tmp/unicorn.socket", :backlog => 64
listen 5000, :tcp_nopush => true

worker_processes 4
timeout 30

0 个答案:

没有答案