frp内网穿透服务端和客户端示例
来源:自通100 发布时间:2024-07-07 21:39:14 浏览:30
frp服务端下载地址:https://github.com/fatedier/frp/releases
frp详细配置参数地址:https://github.com/fatedier/frp/tree/dev/conf
请选择和自己系统匹配的版本进行配置部署
服务端配置
bindPort = 7000
vhostHTTPPort = 8088
auth.method = "token"
# 身份验证令牌 auth.token = “12345678”
auth.token = "12345678"
transport.tls.force = false
# 配置 Web 服务器以启用 frps 的仪表板。
webServer.addr = "0.0.0.0"
webServer.port = 7500
webServer.user = "admin"
webServer.password = "123456"
按以上配置好后,需通过命令:
linux服务器请切换到frp当前目录使用:./frps -c ./frps.toml进行启动
windows系统请切换到frp当前目录使用:frps.exe -c ./frps.toml
启动过程中如果校验通过未报错说明启动成功
客户端配置
serverAddr = "frps.zinzin.cc"
serverPort = 7000
auth.method = "token"
auth.token = "12345678"
[[proxies]]
name = "ssh-树莓派"
type = "tcp"
localIP = "127.0.0.1"
localPort = 22
remotePort = 6000
[[proxies]]
name = "web-定时签到"
type = "http"
localPort = 8924
customDomains = ["sign.home.zinzin.cc"]
[[proxies]]
name = "alist-网盘"
type = "http"
localPort = 5245
customDomains = ["pan.home.zinzin.cc"]
按以上配置好后,需通过命令:
linux服务器请切换到frp当前目录使用: ./frpc -c ./frpc.toml进行启动
windows系统请切换到frp当前目录使用:frpc.exe -c ./frpc.toml进行启动
启动过程中如果校验通过未报错说明启动成功
如何设置服务端和客户端自动启动
参考地址:https://blog.csdn.net/qq_18717111/article/details/133052253
上一篇:到顶了……
下一篇:frp服务端配置大全