** [out :: 192.168.0.200] subversion is asking for a passwordThe solution I used was to use SSH public key authentication instead. Here's a great tutorial. Once that's done, you only need your private key on your client and the public key on your SVN server. Now you either keep following the tutorial to set up ssh agent forwarding or you take the easy way and download SSHKeychain for your Mac. Install it using these instructions (don't forget to enable "Manage global environment variables" in SSHKeychain's Preferences), add it to your Mac's Login Items, log out of your Mac session, and log in again. If everything with the keys is set up correctly, you should be able to log in to your SVN server through Terminal.app without being asked for a password. Ok, now you have to tell Capistrano that it should use ssh agent forwarding. That is required for Capistrano to be able to log in to your SVN server using your key and not requiring a password. So open up deploy.rb and add this line to the SSH OPTIONS section:
ssh_options[:forward_agent] = trueIf cap cold_deploy works now: great. In my case, it threw a strange exception like this one:
Net::SSH::Transport::Session: [:forward_agent] (ArgumentError)That means your net-ssh ruby gem is too old. I think it has to be at least version 1.1.1. So after running
gem update net-sshcap cold_deploy worked like a charm! This great tutorial also helped me a lot.
Comments
Wilson said...
Thanks! This was a huge help for me this evening and something that's not obvious for everyone.
May 18, 2008 03:52 AM
codesnik said...
thank you very much, your post helped me a lot.
August 13, 2008 08:09 PMI still wonder why default net/ssh ":config => true" option doesn't take into account ForwardAgent value in my .ssh/config
maybe some bug in net/ssh. I'm going to look deeply into code tomorrow.