SSH Config
~/.ssh/config
– Feine Sache das…
Globbing
Host one two three
Hostname %h.local
IdentityFile ~/.ssh/home_25519
User user
Host *example.net
Hostname host.example.net
IdentityFile ~/.ssh/example_25519
User user
Port 23
Host jail.example.net
IdentityFile ~/.ssh/example_jail_25519
User deploy
Port 2323
Command | Connection |
---|---|
ssh one | user@one.local:22 |
ssh example.net | user@host.example.net:23 |
ssh whatever.example.net | user@host.example.net:23 |
ssh jail.example.net | deploy@host.example.net:2323 |
*
Host *
AddKeysToAgent yes
PreferredAuthentications publickey
VisualHostKey yes
AddKeysToAgent
– Im ssh-agent die Keys halten.PreferredAuthentications publickey
– Keys-First, Bedenken second!VisualHostKey
– Spielzeug…
StrictHostKeyChecking
Wenn sich die Host-Keys ändern (Server wird installiert, System hat nur eine RAM-Disk)…
Host setup
StrictHostKeyChecking no
IdentityFile ~/.ssh/key_ed25519
Host 10.11.1.11
User rescue
Oder halt so:
ssh -o StrictHostKeyChecking=no -i ~/.ssh/key_ed25519 rescue@10.11.1.11
last update: 2025-01-25 11:14:03 +0100