Skip to content

Instantly share code, notes, and snippets.

@gbraccialli
Created December 22, 2016 15:52
Show Gist options
  • Save gbraccialli/5f31bf11419586c652f63afe010a8f64 to your computer and use it in GitHub Desktop.
Save gbraccialli/5f31bf11419586c652f63afe010a8f64 to your computer and use it in GitHub Desktop.
chmod 400 ~/.ssh/field.pem
cat >> ~/.ssh/config << EOF
Host *.field.xxxx.com
IdentityFile ~/.ssh/field.pem
CheckHostIP=no
StrictHostKeyChecking=no
User centos
UserKnownHostsFile=/dev/null
## Automatically restore a connection if reconnected within 5 minutes (in case the VPN drops)
TCPKeepAlive no
ServerAliveInterval 60
ServerAliveCountMax 5
## reuses the ssh connection making things much faster
ControlMaster auto
ControlPath /tmp/.ssh_%h_%p_%r
ControlPersist 600
EOF
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment