
答案1
你的本機必須運行 ssh,然後你可以這樣做
localusername@localmachine: ssh username@server -R 10000:localmachine:22
username@server: cd /var
username@server: sshfs -p 10000 -o idmap=user,nonempty \
[email protected]:~/mywwwdevelstuff www
答案2
我首先將scp
本地文件傳輸到遠端伺服器。
當然,在本機系統上安裝 gvim 可能會更好。
答案3
您可以像這樣在遠端電腦上執行程式:
ssh -t <user>@<remote host> '<program to execute with full path and arguments>'
-t Force pseudo-terminal allocation. This can be used to execute arbitrary
screen-based programs on a remote machine, which can be very useful, e.g.
when implementing menu services. Multiple -t options force tty allocation,
even if ssh has no local tty.