Skip to content

Instantly share code, notes, and snippets.

@my-janala
Last active October 13, 2016 08:04
Show Gist options
  • Save my-janala/bfdaafd799d8fb144e66cc05bdc16d8b to your computer and use it in GitHub Desktop.
Save my-janala/bfdaafd799d8fb144e66cc05bdc16d8b to your computer and use it in GitHub Desktop.
$ vim ~/.ssh/config
###
Host *.sunrise-dev.local
user mezbaur
ProxyCommand ssh -q -A mezbaur@cd_bstn nc %h %p
IdentityFile ~/.ssh/mezbaur
LogLevel QUIET
StrictHostKeyChecking no
###
Host cd_bstn
Hostname <bastion_host>
User mezbaur
Port 20022
IdentityFile ~/.ssh/mezbaur
ForwardAgent yes
ServerAliveInterval 120
ControlMaster auto
ControlPath ~/.ssh/%%h-%%r
ControlPersist 10m
ProxyCommand none
LogLevel QUIET
StrictHostKeyChecking no
@my-janala
Copy link
Author

The key is ControlMaster together with ControlPath.

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