Skip to content

Instantly share code, notes, and snippets.

@philips
Last active August 29, 2015 13:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save philips/9108489 to your computer and use it in GitHub Desktop.
Save philips/9108489 to your computer and use it in GitHub Desktop.
Howto get an ssh agent forwarded into your vagrant host.

Setup your ssh client so it can ssh into your vagrant machine like a regular host:

vagrant ssh-config --host coreos-vagrant >> ~/.ssh/config
vagrant ssh-config --host coreos-vagrant | sed -n "s/IdentityFile//gp" | xargs ssh-add

Login! Using 'ssh -A' forwards an agent from your host machine into your vagrant machine.

ssh -A coreos-vagrant 
@rberger
Copy link

rberger commented Feb 20, 2014

Should be:

ssh -A coreos-vagrant

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment