Iliya Stepanov
Iliya Stepanov

Reputation: 113

Trouble with deploy

I faced with capistrano deploy problem. I use RVM, Rails 3.2.13, Ruby 1.9.3, Nginx, Unicorn. CentOS 6.4 on server and Mac OSX on local machine.

   command finished in 482ms
 ** transaction: commit
  * 2013-08-01 22:11:25 executing `deploy:restart'
  * executing "if [ -f /home/deployer/fashion/shared/pids/unicorn.pid ]; then kill -USR2 `cat /home/deployer/fashion/shared/pids/unicorn.pid`; else cd /home/deployer/fashion/current && bundle exec unicorn -c /home/deployer/fashion/current/config/unicorn.rb -E production -D; fi"
    servers: ["91.211.216.150"]
    [91.211.216.150] executing command
 ** [out :: 91.211.216.150] bash: line 0: kill: (65424) - No such process
    command finished in 477ms
failed: "rvm_path=$HOME/.rvm/ $HOME/.rvm/bin/rvm-shell 'ruby-1.9.3-p448@fashion' -c 'if [ -f /home/deployer/fashion/shared/pids/unicorn.pid ]; then kill -USR2 `cat /home/deployer/fashion/shared/pids/unicorn.pid`; else cd /home/deployer/fashion/current && bundle exec unicorn -c /home/deployer/fashion/current/config/unicorn.rb -E production -D; fi'" on 91.211.216.150

Upvotes: 0

Views: 380

Answers (1)

Winfield
Winfield

Reputation: 19145

Your deploy is trying to kill a unicorn process that doesn't exist, because of a stale pidfile at /home/deployer/fashion/shared/pids/unicorn.pid.

rm /home/deployer/fashion/shared/pids/unicorn.pid

and re-deploy, you should be all set.

Upvotes: 1

Related Questions