Frp github地址:https://github.com/fatedier/frp
Frp分为两个部分,frps.exe和frpc.exe。
frps.exe为服务端运行于具有公网ip的服务器上。
frpc.exe为客服端运行于需要进行内网穿透的电脑上。
以下是frps的配置文件:
[common]
#服务端的端口和监听端口
bind_port = 7000
#密钥
token = xxxxxx
#设置frp服务的网页监控面板端口和账号密码信息
dashboard_port = 7500
dashboard_user = xxxxxx
dashboard_pwd = xxxxxx
#frp内网穿透服务器可以支持虚拟主机的http和https协议,一般我们都用80,可以直接用域名而不用增加端口号,如果使用其它端口,那么客户端也需要配置相同的其他端口。
vhost_http_port = 80
vhost_https_port = 443
以下是frpc的配置文件:
[common]
#服务端的ip地址和端口
serverAddr = "x.x.x.x"
serverPort = 7000
#密钥
token = xxxxxx
[name]
#网络协议
type = tcp
#本地ip
local_ip = 127.0.0.1
#本地端口
local_port = xx
#远程端口
remote_port = xx
#域名
customDomains = www.example.com
