2014-04-30 25 views
4

当我使用capistrano 3进行部署时,出现错误,但它不是致命的,最终部署成功。在部署capistrano3时写入身份验证套接字时出错

我的错误信息是: 错误写入

此错误消息显示出3次验证插座。

像这样:

DEBUG [ac3445fe] Command: (GIT_ASKPASS=/bin/echo GIT_SSH=/tmp/my-project/git-ssh.sh /usr/bin/env git ls-remote -h [email protected]:me/my-project.git) 
DEBUG [ac3445fe] Error writing to authentication socket. 
DEBUG [ac3445fe] b9e8e722970ec7980e2062f481e7147bde7e7363 refs/heads/branch1 
DEBUG [ac3445fe] 1a23c87450e24a83aa97c4765750c60d683ecf36 refs/heads/master 
DEBUG [ac3445fe] fc070f0e7c0b44bb0ae519beced3e00cb0dbc6cb refs/heads/branch2 
DEBUG [ac3445fe] 2936c7921bdae0003d845dde142bf8b11f29f0a3 refs/heads/branch3 
DEBUG [ac3445fe] Error writing to authentication socket. 
DEBUG [ac3445fe] Finished in 7.479 seconds with exit status 0 (successful). 

这:

DEBUG [2c4bb65f] Command: cd /var/www/my-project/repo && (GIT_ASKPASS=/bin/echo GIT_SSH=/tmp/my-project/git-ssh.sh /usr/bin/env git remote update) 
DEBUG [2c4bb65f] Fetching origin 
DEBUG [2c4bb65f] Fetching origin 
DEBUG [2c4bb65f] Error writing to authentication socket. 

我可以用这个错误的工作,但如果我能解决的话,会更好:)

+0

是否从此配置(user/ssh-key)中的第一次部署中显示错误? – florianb

+0

此错误始终显示在所有部署中 – Ramazan

回答

1

这看起来像一个问题与ssh-agent。你开始ssh-agent正确吗?尝试:

ssh-agent bash 
ssh-add /path/to/your/private_key 
run-your-command-again 

如果一切正常,请确保您的操作系统启动ssh-agent正常,并且您的密钥(S)被添加到该直接对您的桌面会话的启动。这会让你的生活变得更加轻松,因为每次你打开一个新的终端时,你都不必重复上述操作。当然,您可以将这些行添加到您的.bashrc,但是如果您使用密码保护了您的密钥,那么您每次打开新的shell时都需要输入密码。

相关问题