Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ## a list of hostnames otherwise not known to my laptop,
- ## i. e. not in /etc/hosts
- ## at home, in my local network, "ssh server" will connect me to the server
- Host server
- Host archpi
- Host banana
- Host uncle
- Host router
- Host dlna
- Host osmc
- Host vostro
- Host xps
- Host thor
- Host hp
- ## the jump host
- Host jump
- HostName my.dynamicdns.com
- Port 2222
- IdentityFile ~/.ssh/my-jump/remote_ed25519
- ControlMaster auto
- ControlPath ~/.ssh-cm-socket/%r@%h:%p
- ## the forwarding rule which does not work
- DynamicForward 1080
- ## abroad, this stanza together with the * stanza will connect me
- ## to the hosts above via the jump host.
- ## Yes, private ssh keys sit in subdirectories. %h will resolve as
- ## "server/remote" here, resulting in ~/.ssh/my-server/remote_ed25519;
- ## $(dirname %h) will simply be "server"
- Host */remote
- IdentityFile ~/.ssh/my-%h_ed25519
- ProxyCommand ssh -W $(dirname %h):22 jump
- Ciphers arcfour
- ClearAllForwardings yes
- ## at home, in my local network, "ssh server" will connect me to the server directly.
- ## abroad, via public wifi, and together with the */remote stanza,
- ## "ssh server/remote" will connect me to the server via the jump host.
- ## This identity file seems to be somewhere else, but isn't. In this stanza,
- ## %h will be resolved as "server" to ~/.ssh/my-server/remote_ed25519
- Host *
- Compression yes
- CompressionLevel 1
- ForwardAgent yes
- ServerAliveInterval 60
- User my
- IdentityFile ~/.ssh/my-%h/remote_ed25519
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement