unicornに移行メモ
Apache → Passenger 環境 を unicorn に入れ替える
Gemfileに gem 'unicorn' を追加
bundle installする
bundle binstubs unicorn
で
unicorn、unicorn_rails を bin配下に作成
init.dに起動シェル作成しておいて
${RAILS_ROOT}/bin/unicorn_rails -c config/unicorn.rb
などで呼び出せるようにしておく
apacheからSSLでうまく通信できないのでhttp.confに
RequestHeader set X_FORWARDED_PROTO 'https'
を追加 Proxyの設定も追加する
ProxyPass http://hogehoge.com:4000
ProxyPassReverse http://hogehoge.com:4000
これらを設定に追加すればOK あとはチューニング