ssh remote

This commit is contained in:
veypi 2025-11-21 18:53:42 +08:00
parent 4400e24dca
commit ab3ef79e7c
2 changed files with 12 additions and 0 deletions

View File

@ -23,5 +23,6 @@ $$
[^1]: https://veypi.com

11
linux/ssh.md Normal file
View File

@ -0,0 +1,11 @@
# ssh 代理
```bash
# 将本地的 2017 端口映射到远程服务器的 8022 端口
ssh -R 8022:localhost:2017 user@ip -N
# 将远程服务器的 8022 端口映射到本地的 2017 端口
ssh -L 2017:localhost:8022 user@ip -N
```