ControlPath and differing ssh options?
Brian Candler
b.candler at pobox.com
Thu Jan 30 22:52:40 AEDT 2025
On 28/01/2025 13:50, Jan Schermer wrote:
> If one wants to go this way, then I just discovered Tags
>
> it should work like this (I haven’t tested it and never used tags)
>
> Match tagged FA
> ForwardAgent yes
> ControlPath ~/.ssh/controlmaster-%r@%h-%p-forwardagent
> ControlMaster off
There's no need to turn off ControlMaster though; any additional
connections with ForwardAgent can also share that alternative socket.
I now have at end of ~/.ssh/config:
Match Tagged A
ForwardAgent yes
ControlPath %d/tmp/ssh_mux-A_%h_%p_%r
Host *
ControlMaster auto
ControlPersist 2
ControlPath %d/tmp/ssh_mux_%h_%p_%r
ServerAliveInterval 240
AddKeysToAgent 20h
and I can use "ssh -PA" instead of "ssh -A". Thanks!
More information about the openssh-unix-dev
mailing list