Initial commit: sing-box Reality + Hysteria2 deploy for 66.hyf2.cc
Ubuntu deployment at /opt/jiedian with pre-filled env for 47.76.87.111. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,152 @@
|
||||
# 客户端导入与测试指南
|
||||
|
||||
部署完成后,在 VPS 上查看 `client/generated/share-links.txt`,或本地运行 `bash scripts/render-client.sh` 生成链接。
|
||||
|
||||
---
|
||||
|
||||
## 一、连通性测试(推荐顺序)
|
||||
|
||||
### 1. Reality(TCP 443)
|
||||
|
||||
在**国内网络**下测试(不要在 VPS 本机 curl 自己):
|
||||
|
||||
```bash
|
||||
# Windows PowerShell — 仅测端口是否可达
|
||||
Test-NetConnection -ComputerName YOUR_VPS_IP -Port 443
|
||||
```
|
||||
|
||||
客户端连上后访问 https://www.google.com 或 https://ip.sb 确认出口 IP 为 VPS。
|
||||
|
||||
### 2. Hysteria2(UDP 8443)
|
||||
|
||||
UDP 无法用普通 TCP 工具测。直接导入客户端测试;若 Reality 可用但 Hysteria2 不通,可能是运营商 QoS/封锁 UDP,可继续只用 Reality。
|
||||
|
||||
### 3. 故障判断
|
||||
|
||||
| 现象 | 可能原因 |
|
||||
|------|----------|
|
||||
| ping 通 IP,客户端 timeout | 协议层问题,检查 UUID/密钥/SNI |
|
||||
| ping 不通 | IP 可能被封,考虑换 IP |
|
||||
| 连接成功但无网 | 检查 VPS 防火墙、sing-box 日志 `journalctl -u sing-box -f` |
|
||||
| Hysteria2 不通,Reality 正常 | UDP 被干扰,备用节点可忽略 |
|
||||
|
||||
---
|
||||
|
||||
## 二、Windows
|
||||
|
||||
### 方案 A:v2rayN(推荐,上手快)
|
||||
|
||||
1. 下载 [v2rayN](https://github.com/2dust/v2rayN/releases)(选 `v2rayN-With-Core.zip`)
|
||||
2. 解压运行,托盘图标 → **服务器** → **从剪贴板导入批量 URL**
|
||||
3. 复制 `share-links.txt` 中的 `vless://...` 行到剪贴板,导入
|
||||
4. 再导入 `hy2://...` 行作为备用
|
||||
5. 右键节点 → **设为活动服务器**,路由选 **绕过大陆**
|
||||
6. 系统代理 → **自动配置系统代理**
|
||||
|
||||
**手动核对 Reality 参数:**
|
||||
|
||||
| 字段 | 值 |
|
||||
|------|-----|
|
||||
| 地址 | VPS IP |
|
||||
| 端口 | 443 |
|
||||
| 用户 ID | `.env` 中的 UUID |
|
||||
| 流控 | xtls-rprx-vision |
|
||||
| 传输 | tcp |
|
||||
| 安全 | reality |
|
||||
| SNI | www.microsoft.com(或你设的 REALITY_SERVER_NAME) |
|
||||
| Fingerprint | chrome |
|
||||
| Public Key | REALITY_PUBLIC_KEY |
|
||||
| Short ID | REALITY_SHORT_ID |
|
||||
|
||||
### 方案 B:sing-box 客户端
|
||||
|
||||
1. 下载 [sing-box for Windows](https://github.com/SagerNet/sing-box/releases)
|
||||
2. 将 `client/generated/sing-box-client.json` 放入配置目录
|
||||
3. 以管理员运行(TUN 模式需要),启动后选择 `reality` 出站
|
||||
|
||||
### 方案 C:Nekoray
|
||||
|
||||
1. 下载 [Nekoray](https://github.com/MatsuriDayo/nekoray/releases)
|
||||
2. **Program → Add profile from clipboard**,粘贴 `vless://` 链接
|
||||
3. 右键 → **Start**
|
||||
|
||||
---
|
||||
|
||||
## 三、Android
|
||||
|
||||
### v2rayNG(推荐)
|
||||
|
||||
1. [Google Play](https://play.google.com/store/apps/details?id=com.v2ray.ang) 或 [GitHub Releases](https://github.com/2dust/v2rayNG/releases) 安装
|
||||
2. 右上角 **+** → **从剪贴板导入**(先复制 `vless://` 链接)
|
||||
3. 再导入 `hy2://` 备用节点
|
||||
4. 点击右下角 **V** 连接
|
||||
5. 设置 → **路由设置** → **绕过局域网及大陆地址**
|
||||
|
||||
### sing-box for Android
|
||||
|
||||
1. [GitHub Releases](https://github.com/SagerNet/sing-box/releases) 安装 APK
|
||||
2. **Profiles** → **+** → 导入 `sing-box-client.json`
|
||||
3. 开启 **Service**
|
||||
|
||||
---
|
||||
|
||||
## 四、iOS
|
||||
|
||||
需要美区 Apple ID 或已有购买记录。
|
||||
|
||||
### Shadowrocket(小火箭)
|
||||
|
||||
1. App Store 购买安装 Shadowrocket
|
||||
2. 首页右上角 **+** → **类型选 NONE** → 右上角 **扫描或从剪贴板导入**
|
||||
3. 粘贴 `vless://` 链接,自动填充 Reality 参数
|
||||
4. 再添加 `hy2://` 备用
|
||||
5. 连接后 **连通性测试** 应显示延迟
|
||||
|
||||
**手动添加 Reality:**
|
||||
|
||||
- 类型:VLESS
|
||||
- 地址:VPS IP
|
||||
- 端口:443
|
||||
- UUID:你的 UUID
|
||||
- 传输方式:none
|
||||
- TLS:开启 → 类型 **REALITY**
|
||||
- SNI:REALITY_SERVER_NAME
|
||||
- Public Key / Short ID:从 `.env` 复制
|
||||
- uTLS:chrome
|
||||
- Flow:xtls-rprx-vision
|
||||
|
||||
### Streisand
|
||||
|
||||
1. App Store 安装 Streisand
|
||||
2. **+** → **Import from Clipboard**,粘贴链接
|
||||
3. 连接
|
||||
|
||||
---
|
||||
|
||||
## 五、macOS
|
||||
|
||||
与 Windows 类似:
|
||||
|
||||
- **V2rayU** / **Nekoray** / **sing-box for Apple platforms**
|
||||
- 从剪贴板导入 `vless://` 和 `hy2://` 链接
|
||||
|
||||
---
|
||||
|
||||
## 六、日常使用建议
|
||||
|
||||
1. **默认节点**:Reality(`vless://`)
|
||||
2. **备用节点**:Hysteria2(看视频卡顿时可切换)
|
||||
3. **不要分享**节点链接;每设备保存一份即可
|
||||
4. **每月检查**:`systemctl status sing-box`、证书是否续期(acme.sh 自动)
|
||||
|
||||
---
|
||||
|
||||
## 七、分享链接格式参考
|
||||
|
||||
```
|
||||
vless://UUID@IP:443?encryption=none&flow=xtls-rprx-vision&security=reality&sni=SNI&fp=chrome&pbk=PUBLIC_KEY&sid=SHORT_ID&type=tcp#名称
|
||||
|
||||
hy2://PASSWORD@DOMAIN:8443?sni=DOMAIN#名称
|
||||
```
|
||||
|
||||
完整链接见部署后生成的 `client/generated/share-links.txt`。
|
||||
Reference in New Issue
Block a user