dimanche 27 avril 2014

Ruby sur rails - Capistrano ne peut déployer du code, parce que Net::SSH::AuthenticationFailed : l'authentification a échoué - Stack Overflow


We have a Rails app that is running on Amazon AWS. We're pushing there a new code almost every day for a few months in a row.


Today, when I tried to deploy a new code there, I was given this error message:


  * 2014-02-16 13:09:51 executing `deploy'
* 2014-02-16 13:09:51 executing `deploy:update'
** transaction: start
* 2014-02-16 13:09:51 executing `deploy:update_code'
updating the cached checkout on all servers
executing locally: "git ls-remote git@bitbucket.org:my_bitbucket_name/project_name.git master"
command finished in 2909ms
* executing "if [ -d /home/deployer/project_name/shared/cached-copy ]; then cd /home/deployer/project_name/shared/cached-copy && git fetch -q origin && git fetch --tags -q origin && git reset -q --hard 16958dfcee27dd9c33855ecece0013428e2c57c8 && git clean -q -d -x -f; else git clone -q -b master git@bitbucket.org:rdudacz/looky.co.git /home/deployer/looky/shared/cached-copy && cd /home/deployer/project_name/shared/cached-copy && git checkout -q -b deploy 16958dfcee27dd9c33855ecece0013428e2c57c8; fi"
servers: ["IP"]
*** [deploy:update_code] rolling back
* executing "rm -rf /home/deployer/project_name/releases/20140216120957; true"
servers: ["IP"]
** [deploy:update_code] exception while rolling back: Capistrano::ConnectionError, connection failed for: IP (Net::SSH::AuthenticationFailed: Authentication failed for user deployer@IP)
connection failed for: IP (Net::SSH::AuthenticationFailed: Authentication failed for user deployer@IP)

What happened here? Where to start with looking for the issue?


Thank you in advance




The problem is the gem



net-ssh



The last version (2.8.0) causes this issue. The solution is to uninstall it:


gem uninstall net-ssh -v 2.8.0

and then to add to the Gemfile its previous version:


gem "net-ssh", "~> 2.7.0"

That's it.




After uninstall net-ssh 2.8.0, remove on gemfile.lock, too. It will continuously okay.



We have a Rails app that is running on Amazon AWS. We're pushing there a new code almost every day for a few months in a row.


Today, when I tried to deploy a new code there, I was given this error message:


  * 2014-02-16 13:09:51 executing `deploy'
* 2014-02-16 13:09:51 executing `deploy:update'
** transaction: start
* 2014-02-16 13:09:51 executing `deploy:update_code'
updating the cached checkout on all servers
executing locally: "git ls-remote git@bitbucket.org:my_bitbucket_name/project_name.git master"
command finished in 2909ms
* executing "if [ -d /home/deployer/project_name/shared/cached-copy ]; then cd /home/deployer/project_name/shared/cached-copy && git fetch -q origin && git fetch --tags -q origin && git reset -q --hard 16958dfcee27dd9c33855ecece0013428e2c57c8 && git clean -q -d -x -f; else git clone -q -b master git@bitbucket.org:rdudacz/looky.co.git /home/deployer/looky/shared/cached-copy && cd /home/deployer/project_name/shared/cached-copy && git checkout -q -b deploy 16958dfcee27dd9c33855ecece0013428e2c57c8; fi"
servers: ["IP"]
*** [deploy:update_code] rolling back
* executing "rm -rf /home/deployer/project_name/releases/20140216120957; true"
servers: ["IP"]
** [deploy:update_code] exception while rolling back: Capistrano::ConnectionError, connection failed for: IP (Net::SSH::AuthenticationFailed: Authentication failed for user deployer@IP)
connection failed for: IP (Net::SSH::AuthenticationFailed: Authentication failed for user deployer@IP)

What happened here? Where to start with looking for the issue?


Thank you in advance



The problem is the gem



net-ssh



The last version (2.8.0) causes this issue. The solution is to uninstall it:


gem uninstall net-ssh -v 2.8.0

and then to add to the Gemfile its previous version:


gem "net-ssh", "~> 2.7.0"

That's it.



After uninstall net-ssh 2.8.0, remove on gemfile.lock, too. It will continuously okay.


Related Posts:

0 commentaires:

Enregistrer un commentaire