facebook twitter hatena line email

「Ruby/rails/git」の版間の差分

提供: 初心者エンジニアの簡易メモ
移動: 案内検索
(ページの作成:「==git_cloneしてからプロジェクト開始方法== git clone git@bitbucket.org:hogeacount/hogeproject.git hogeproject-test log権限変更 chmod 777 log chmod 66...」)
 
(git_cloneしてからプロジェクト開始方法)
 
(同じ利用者による、間の1版が非表示)
行5: 行5:
 
  chmod 777 log
 
  chmod 777 log
 
  chmod 666 log/*.log
 
  chmod 666 log/*.log
 +
 +
==以下エラーが出たとき==
 +
If you are the application owner check the logs for more information.
 +
log/unicorn_error.logなどを確認
  
 
==unicornでEADDRINUSEなエラーが出たとき==
 
==unicornでEADDRINUSEなエラーが出たとき==
行11: 行15:
 
他と被らないように以下unicorn設定ファイルからlistenのportを変更
 
他と被らないように以下unicorn設定ファイルからlistenのportを変更
  
-config/unicorn.conf
+
config/unicorn.conf
 
  rails_root = File.expand_path('../../', __FILE__)
 
  rails_root = File.expand_path('../../', __FILE__)
 
  worker_processes 2
 
  worker_processes 2

2017年11月12日 (日) 00:12時点における最新版

git_cloneしてからプロジェクト開始方法

git clone git@bitbucket.org:hogeacount/hogeproject.git hogeproject-test

log権限変更

chmod 777 log
chmod 666 log/*.log

以下エラーが出たとき

If you are the application owner check the logs for more information.

log/unicorn_error.logなどを確認

unicornでEADDRINUSEなエラーが出たとき

.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/unicorn-5.3.1/lib/unicorn/socket_helper.rb:164:in `bind': Address already in use - bind(2) for 0.0.0.0:8081 (Errno::EADDRINUSE)

他と被らないように以下unicorn設定ファイルからlistenのportを変更

config/unicorn.conf

rails_root = File.expand_path('../../', __FILE__)
worker_processes 2
working_directory rails_root
listen "#{rails_root}/tmp/unicorn.sock", :backlog => 64
pid "#{rails_root}/tmp/unicorn.pid"
stderr_path "#{rails_root}/log/unicorn_error.log"
stdout_path "#{rails_root}/log/unicorn.log"
listen 8082