Last active
June 4, 2020 15:38
-
-
Save andmax/2ba77d5884ee005b14f8bf6de815b603 to your computer and use it in GitHub Desktop.
Good ssh configuration tips on the ~/.ssh/config file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Strict Host Key Checking avoids know_hosts nuisances | |
Host * | |
Compression Yes | |
ControlMaster auto | |
ControlPath /tmp/ssh-%r@%h:%p | |
ServerAliveInterval 60 | |
StrictHostKeyChecking no | |
# Adding two names to the same host server | |
Host name1 name2 | |
User andmax | |
Port <port other than 22> | |
Hostname <ip or address> | |
IdentityFile ~/.ssh/id_rsa | |
# Access target_name host going thru tunnel_host_name | |
Host target_name | |
HostName <ip or address> | |
User andmax | |
ProxyCommand ssh -aT <tunnel_host_name> nc %h %p |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment