$ ssh -R 52698:localhost:52698 server-name@server-ip -p server-port
$ rmate filename
$ (<filename> does not be opened, nothing responses)
$ ...
将ssh
命令中用于描述本地主机的locaLhost
替换为127.0.0.1
rmate
(下载地址)到目录/usr/bin/local
$ sudo chmod a+x /usr/bin/local/rmate
Remote VScode
插件settings.json
中添加://-------- Remote VSCode configuration --------
// Port number to use for connection.
"remote.port": 52698,
// Launch the server on start up.
"remote.onstartup": true
// Address to listen on.
"remote.host": "127.0.0.1"
// If set to true, error for remote.port already in use won't be shown anymore.
"remote.dontShowPortAlreadyInUseError": false
ctrl + shift + P -> Remote Start Server
ctrl + ~
ssh
连接远程服务器:ssh -R 52698:127.0.0.1:52698 server-name@server-ip -p server-port
$ rmate <filename>