Setting up Vagrant with SSH Forwarding

Thanks to stackoverflow and github, I finally got Vagrant set up so I can ssh into vagrant and pull in my dotfiles from github without futzing with my ssh keys. Here’s the steps:

1) Make sure the ssh key you use for github is registered with your local ssh agent. You can check with ssh-add -L, if it’s not listed add it with ssh-add ~/.ssh/id_rsa. Credit: http://stackoverflow.com/questions/11955525/how-to-use-ssh-agent-forwarding-with-vagrant-ssh

2) Make sure ssh forwarding is enabled in the VM. Include `config.ssh.forward_agent = true` in your Vagrantfile.

3) Test: ssh -T git@github.com. If it’s not working, check out this link for more troubleshooting: https://help.github.com/articles/using-ssh-agent-forwarding

Leave a Reply

Your email address will not be published. Required fields are marked *