SSH 隧道让我很困惑。我想知道我是否可以在 Linux 中做到这一点。
我有3台机器..
A. My local machine at home.
B. Machine at work that I can SSH into (middle man).
C. My desktop at work that I can only SSH into from machine B.
Run Code Online (Sandbox Code Playgroud)
所以我可以从 A -> B 和 B -> C 进行 SSH,但不能从 A -> C 进行 SSH。
有没有办法设置从 A 到 B 的 SSH 隧道,所以当我运行其他 SSH 命令时,它们只能在我的本地机器 A 上工作?我基本上是在尝试将 git repo 从工作克隆到家(并且我无法在机器 B 上安装 git)。
此外,一旦设置.. 我将如何取消设置?