| # [common] 是一个综合部分 | |
| [common] | |
| # 对于IPv6,字面地址或主机名必须用方括号括起来,例如 "[::1]:80"、"[ipv6-host]:http" 或 "[ipv6-host%zone]:80" | |
| bind_addr = 0.0.0.0 | |
| bind_port = 7000 | |
| # 帮助创建UDP洞以穿透NAT的UDP端口 | |
| bind_udp_port = 7001 | |
| # KCP协议使用的UDP端口,可以与'bind_port'相同 | |
| # 如果未设置,则frps中禁用KCP | |
| kcp_bind_port = 7000 | |
| # 指定代理将监听的地址,默认值与bind_addr相同 | |
| # proxy_bind_addr = 127.0.0.1 | |
| # 如果你想支持虚拟主机,必须设置用于监听的HTTP端口(可选) | |
| # 注意:HTTP端口和HTTPS端口可以与bind_port相同 | |
| vhost_http_port = 80 | |
| vhost_https_port = 443 | |
| # 虚拟主机HTTP服务器的响应头超时时间(秒),默认是60秒 | |
| # vhost_http_timeout = 60 | |
| # 设置dashboard_addr和dashboard_port以查看frps的仪表板 | |
| # dashboard_addr的默认值与bind_addr相同 | |
| # 只有设置了dashboard_port,仪表板才可用 | |
| dashboard_addr = 0.0.0.0 | |
| dashboard_port = 7500 | |
| # 仪表板的基本认证保护的用户和密码,如果未设置,默认值都是admin | |
| dashboard_user = admin | |
| dashboard_pwd = admin | |
| # 仪表板资源目录(仅用于调试模式) | |
| # assets_dir = ./static | |
| # 控制台或实际的日志文件路径,例如 ./frps.log | |
| log_file = ./frps.log | |
| # trace, debug, info, warn, error | |
| log_level = info | |
| log_max_days = 3 | |
| # 认证令牌 | |
| token = 12345678 | |
| # 心跳配置,不建议修改默认值 | |
| # heartbeat_timeout 的默认值是90 | |
| # heartbeat_timeout = 90 | |
| # 仅允许frpc绑定你列出的端口,如果未设置,则没有任何限制 | |
| allow_ports = 2000-3000,3001,3003,4000-50000 | |
| # 每个代理中的pool_count超过最大值时将变为max_pool_count | |
| max_pool_count = 5 | |
| # 每个客户端可使用的最大端口数,默认值为0表示无限制 | |
| max_ports_per_client = 0 | |
| # 认证超时指frpc连接frps时的超时间隔(秒) | |
| # 如果authentication_timeout为零,则不验证时间,默认是900秒 | |
| authentication_timeout = 900 | |
| # 如果subdomain_host不为空,当frpc配置文件中的类型为http或https时可以设置子域 | |
| # 当子域为test时,路由使用的主机是test.frps.com | |
| subdomain_host = frps.com | |
| # 如果使用TCP流多路复用,默认为true | |
| tcp_mux = true |