在
.ssh/config
中,我已经为给定域中的所有主机设置了一个RemoteForward
:Host *.[domain]
RemoteForward [remote-port] 127.0.0.1:[local-port]
我如何在某个特定域名下(例如,git.[domain]
)取消设置某个参数?
ssh_config
的 manpage 提到了使用否定来排除某些主机,但仅适用于.ssh/authorized_keys
中的密钥。尝试在.ssh/config
中尝试类似的组合,但没有成功。 - GingiHost !git.[domain],*.[domain]
可以实现你想要的效果。你尝试过哪些组合呢? - dave4420