Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Agent Forwarding #23

Closed
mrrooijen opened this issue Jun 25, 2012 · 6 comments
Closed

[Feature] Agent Forwarding #23

mrrooijen opened this issue Jun 25, 2012 · 6 comments

Comments

@mrrooijen
Copy link

Hi Nadarei,

Agent Forwarding is probably one of the more appealing features of Capistrano. With this option enabled, you won't get this error because it allows you to use your local ssh keys. Normally, like in this case, you have to log in to your server, generate a new SSH key and apply that SSH key to for example Github. Then, this command would work. However with Agent Forwarding you do not need to do that and you can simply use your own local machine's SSH key instead.

-----> Cloning the Git repository
       Initialized empty Git repository in /home/deployer/app/tmp/build-1340639447120/.git/
       Host key verification failed.
       fatal: The remote end hung up unexpectedly

See:

If you're using your own private keys for git, you want to tell Capistrano to use agent forwarding with this command. Agent forwarding can make key management much simpler as it uses your local keys instead of keys installed on the server.

ssh_options[:forward_agent] = true # in Capistrano

It would be great if Mina could also support this feature as it's always pain to add a new key to GitHub for every single server you want to hook up to it.

Note that I looked around and didn't find the option, but if I overlooked something please let me know.

Cheers,
Michael

@mikong
Copy link
Member

mikong commented Jun 27, 2012

Opened an internal discussion in Trello: https://trello.com/c/FH7nfY41

I'll update this issue when there's progress.

Thanks.

@mrrooijen
Copy link
Author

Excellent, thanks!

@branch14
Copy link

Until a more convenient solution is implemented, you can easily achieve this by simply appending or prepending '-A' to another option

set :port, '22 -A'

or even

set :user, '-A youruser'

should work.

+1 for a future

set :ssh_options, '-A'

@mrrooijen
Copy link
Author

Nice one. Didn't even think of that. Tried it and works perfectly. I'll use this until an additional_options string can be passed, or a real forward_agent option becomes available.

@D1plo1d
Copy link

D1plo1d commented Aug 22, 2012

+1 for a forward_agent option.

SSH Agent Forwarding is almost always what I want when deploying, unless other people deploy radically differently regularly forward_agent = true would be a nice default to have.

@rstacruz
Copy link
Member

rstacruz commented Sep 8, 2012

Scheduled for v0.2.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants