惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

P
Palo Alto Networks Blog
Recent Commits to openclaw:main
Recent Commits to openclaw:main
C
CERT Recently Published Vulnerability Notes
C
Cybersecurity and Infrastructure Security Agency CISA
S
Schneier on Security
S
Securelist
酷 壳 – CoolShell
酷 壳 – CoolShell
C
CXSECURITY Database RSS Feed - CXSecurity.com
Cyberwarzone
Cyberwarzone
Apple Machine Learning Research
Apple Machine Learning Research
S
SegmentFault 最新的问题
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
GbyAI
GbyAI
Security Latest
Security Latest
Last Week in AI
Last Week in AI
Microsoft Security Blog
Microsoft Security Blog
云风的 BLOG
云风的 BLOG
Recorded Future
Recorded Future
Webroot Blog
Webroot Blog
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
TaoSecurity Blog
TaoSecurity Blog
C
Cisco Blogs
博客园 - 【当耐特】
Blog — PlanetScale
Blog — PlanetScale
Hugging Face - Blog
Hugging Face - Blog
B
Blog
Hacker News - Newest:
Hacker News - Newest: "LLM"
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Attack and Defense Labs
Attack and Defense Labs
The Last Watchdog
The Last Watchdog
U
Unit 42
阮一峰的网络日志
阮一峰的网络日志
Project Zero
Project Zero
WordPress大学
WordPress大学
L
LINUX DO - 最新话题
F
Fortinet All Blogs
L
LINUX DO - 热门话题
PCI Perspectives
PCI Perspectives
Simon Willison's Weblog
Simon Willison's Weblog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
MongoDB | Blog
MongoDB | Blog
Latest news
Latest news
P
Proofpoint News Feed
T
Threat Research - Cisco Blogs
The Hacker News
The Hacker News
爱范儿
爱范儿
O
OpenAI News
J
Java Code Geeks
T
The Exploit Database - CXSecurity.com
H
Hackread – Cybersecurity News, Data Breaches, AI and More

博客园 - SharpCJ

Dart 基础入门 在 JetBrains IDE 中接入 OpenCode 并配置自定义模型 理解 Agent 中的 Slash Command:从概念到自定义命令实践 Harness Engineering:把 AI 真正接进工程流程 当 AI 开始写代码,谁来保证它不会翻车? Android 开发者为什么必须掌握 AI 能力?端侧视角下的技术变革 拆穿名词诈骗!用大白话理解晦涩难懂的AI概念 OpenClaw 大结局——接入个人微信 Android 性能分析工具 Perfetto 的基本使用 LangChain入门学习 Ubuntu 下 conda 设置 ComfyUI 基础教程(六) —— 图像的局部重绘 ComfyUI 基础教程(五) —— 应用 IP-Adapter 实现图像风格迁移 ComfyUI 基础教程(四) —— 应用 LoRA 模型控制图像生成特征 ComfyUI 基础教程(三) —— 应用 Controlnet 精准控制图像生成 ComfyUI 基础教程(二) —— Stable Diffusion 文生图基础工作流及模型、常用节点介绍 ComfyUI 基础教程(一) —— 本地安装部署 Stable Diffusion 小白的入坑铺垫 GPT-SoVITS —— 5s 声音样本就可以训练模型,复刻声音的 AI 应用 LM Studio + open-webui 快速本地部署大语言模型 Jetpack Compose(9)——自定义Composable Compose 延迟列表踩过的坑 Jetpack Compose(8)——嵌套滚动 Jetpack Compose(7)——触摸反馈
frp 内网穿透 0.63.0 教程
SharpCJ · 2025-07-03 · via 博客园 - SharpCJ

一、资源

一台具有公网 IP 的云服务器

二、安装 frp

2.1 服务端与客户端

简单理解,frp 原理是通过服务端与客户端程序进行数据转发。具有公网 ip 的服务器充当服务端角色,需要进行内网穿透的个人电脑充当客户端角色。

2.2 安装

我这边下载了最新版的 frp 程序。可以到 github 上下载 frp 的 release 包。
我这里服务端是 Linux 系统,客户端是 Windows 系统,分别下载对应的包即可。该包解压就可以使用,无需安装。

2.3 配置并启动 frp 进程

在使用之前,需要进行一些配置。不同版本配置文件格式不一致,早起可能是 .ini 或其它格式。本文以当前最新版 0.63.0 版本为例,配置文件是 toml 格式。
服务端配置文件 frps.toml

bindAddr = "0.0.0.0" # 服务端监听地址,用于接收 frpc 的连接。默认监听 0.0.0.0, 表示监听所有网络接口。
bindPort = 7000 # 服务端监听端口,默认值为 7000,客户端通过此端口连接。
vhostHTTPPort = 7001 # 接收http请求
auth.token = "myfrptoken" # 客户端需要配置对应的token才允许映射

#仅允许服务器上的指定端口/端口范围 避免滥用端口
allowPorts = [
  # 范围指定
  { start = 5000, end = 5500},
  # 单独指定
  # { single = 5501},
]

# 仪表盘配置
# The default value is 127.0.0.1. Change it to 0.0.0.0 when you want to access it from a public network.
webServer.addr = "0.0.0.0"
webServer.port = 7002
webServer.user = "admin"
webServer.password = "admin"

服务端配置完成之后,通过 ./frps -c ./frps.toml 启动。启动之前,记得把公网服务器的 7000, 7001,7002 的端口打开, 5000-5500 用到哪个打开哪个。一般可以通过购买的服务器的控制台进行设置。

客户端配置文件为 frpc.toml

serverAddr = "你的服务器 ip"
serverPort = 7000  # 和服务端进行通信的端口,与服务端 bindPort 保持一致。
auth.token = "myfrptoken" # token 校验,和服务端保持一致。

[[proxies]]
name = "comfyui" # 要映射的服务名,随便起。比如我想映射本机的 comfyui 进程。
type = "tcp"
localIP = "0.0.0.0"
localPort = 8188 # 本机需要映射的端口,比如本机 comfyui 进程端口是 8188
remotePort = 5000 #映射到云服务器的哪个端口,需要打开服务器的这个端口。

客户端的 proxies 可以配置多个。针对不沟通的服务,启动不同的端口即可。

其它网络通过 http://云服务器ip:remotePort 即可访问你本地机器 localPort 对应的进程。

2.4 其它

可以将服务端和客户端程序,设置为开机启动。