服務端的配置
# frps.ini
[common]
bind_port = 7000
說明:防火墻放行該端口
啟動:./frps -c ./frps.ini
后臺啟動:nohup ./frps -c ./frps.ini &
?
客戶端的配置
(1)windows系統
# frpc.ini
[common]
server_addr = x.x.x.x
server_port = 7000
[desktop]
type = tcp
local_ip = 127.0.0.1
local_port = 3389
remote_port = 6000
命令行啟動: ./frpc -c ./frpc.ini
連接:遠程桌面
?
(2)linux系統
# frpc.ini
[common]
server_addr = x.x.x.x
server_port = 7000
[ssh]
type = tcp
local_ip = 127.0.0.1
local_port = 22
remote_port = 6001
啟動:./frpc -c ./frpc.ini
連接:ssh -oPort=6001 test@x.x.x.x
注:test為內網機器的用戶名,x.x.x.x為服務器的公網IP,連接時需要輸入內網test用戶的密碼
?