cap deploy:setup hangs?

蹲街弑〆低调 提交于 2020-01-02 19:21:08

问题


Im having setup a empty git repo bare on the server side and everything setup.

Cap deploy:setup does this

    [109.etc] env RAILS_ENV=production sh -c 'git clone git@109.etc:srv/paintings.git /srv/paintings/current'
 ** [out :: 109.etc] Initialized empty Git repository in /srv/paintings/current/.git/
 ** [out :: 109.etc] The authenticity of host '109.etc (109.etc)' can't be established.
 ** [out :: 109.etc] RSA key fingerprint is e9:af:d6:d3:0e:f5:de:a3:4a:31:6e:8e:4a:c7:b7:ee.
 ** [out :: 109.etc] Are you sure you want to continue connecting (yes/no)?

*When I type yes or y it just "hangs" nothing seem to happen... * already tried --debug after the cap deploy:setup what could be wrong?


回答1:


Capistrano is essentially non-interactive; if a prompt like this pops up you can't just tell it "yes", unfortunately, since commands you type in aren't sent to the remote host. You'll have to do the "yes"-ing manually.

To get around this problem, add the host's key to the known_hosts file for that user. So, SSH into whatever machine is doing the deploy, su into that user, and try SSHing into 109.etc. You'll receive the same warning prompt and you'll be able to enter "yes" in, and this time it'll work. Afterwards, cap deploy as per normal and you won't receive this message anymore.



来源:https://stackoverflow.com/questions/9723029/cap-deploysetup-hangs

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!