> Yeah, the connection issue is related to .ssh/config, then. I have no
> idea what the correct behavior should be when there are two host entries
> for the same IP? As I understand it, the IP's should be unique in there.
With no username (`ssh -p [port] [remote-host-ip]`), `ssh` logs into
the server with the first login name for the [remote-host-ip] (~/.ssh/
config). That's how Capistrano is doing now.
I'd expect for Capistrano to look for the key of `ssh_options
[:username]` login.
In terminal:
$ ssh -p [port] local-usern...@[remote-host-ip]
uses ~/.ssh/vps_me_rsa
$ ssh -p [port] rails-app-u...@[remote-host-ip]
uses ~/.ssh/vps_rails_app_rsa
> As for the failed check, what are the permissions on those directories?
> Are they sufficient for rails-app-user to write to them?
I overlooked ':deploy_to'. I should have set ':deploy_to, "/home/#
{application}/rails"', not "/home/users/#{application}/rails".
Now I'm investigating how to deploy my app when I've a separate user
for Git access. Temporarily, I set rails-app-user to be the first
listed in ssh config. `cap deploy` fails:
executing locally: "git ls-remote
ssh://g...@[remote-host-ip]:[port]/home/git/rails-app-user
master"
* executing "if [ -d /home/rails-app-user/rails/shared/cached-copy ];
then cd /home/rails-app-user/rails/shared/cached-copy && git fetch -q
origin && git reset -q --hard
57b8b1801d3202a9a7fa86077719c15b18ecd21b; else git clone -q
ssh://g...@[remote-host-ip]:[port]/home/git/rails-app-user /home/rails-
app-user/rails/shared/cached-copy && cd /home/rails-app-user/rails/
shared/cached-copy && git checkout -q -b deploy
57b8b1801d3202a9a7fa86077719c15b18ecd21b; fi"
servers: ["[remote-host-ip]"]
[[remote-host-ip]] executing command
** [[remote-host-ip] :: err] Host key verification failed.
** [[remote-host-ip] :: err] fatal: The remote end hung up
unexpectedly
** [[remote-host-ip] :: err] fetch-pack from 'ssh://g...@[remote-host-
ip]:[port]/home/git/rails-app-user' failed.
command finished
--~--~---------~--~----~------------~-------~--~----~
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at http://groups.google.com/group/capistrano
-~----------~----~----~----~------~----~------~--~---