跳转到内容
Doc Record

frp+ssh+docker打通受限网络(client)

必须配置项:

  • serverAddr
  • serverPort
  • auth.token
  • proxies.name
  • proxies.customDomains
{
// 必须参数
"serverAddr": "55.44.33.33",
// 必须参数
"serverPort": 18000,
"auth": {
"method": "token",
// 必须参数
"token": "frps-ssh"
},
"loginFailExit": false,
"transport": {
"heartbeatInterval": 25,
"heartbeatTimeout": 120,
"poolCount": 10,
"tcpMux": true
},
"proxies": [
{
// 必须参数
"name": "frpc-ssh-fa",
"type": "tcpmux",
"multiplexer": "httpconnect",
// 必须参数
"customDomains": ["fa.intranet.company"],
"localIP": "127.0.0.1",
"localPort": 22
}
]
}
终端窗口
# 服务端配置
# sudo nano /etc/ssh/sshd_config
# 每60秒向客户端发送心跳
ClientAliveInterval 60
# 允许5次心跳失败(总共300秒)
ClientAliveCountMax 5
# 启用TCP保活
TCPKeepAlive yes