This commit is contained in:
riglen
2026-04-09 11:33:52 +08:00
parent 5c86136912
commit 38fd7063d4
3 changed files with 29 additions and 18 deletions

View File

@@ -7,7 +7,7 @@
这一版已经补上:
- 多机场源选择:`?sources=airport-a,airport-b`
- 多机场源选择:`?sources=airport-a,airport-b,airport-c`
- 单机场或多机场时,**始终取第一个源**的 `Subscription-Userinfo` 返回给客户端
- `GET``HEAD` 都支持
- provider 单源输出、merged provider 输出、thin client 输出、bundle 输出
@@ -69,7 +69,7 @@ cp .env.example .env
- `PUBLIC_PATH` 改成足够长的随机字符串
- `PUBLIC_BASE_URL` 建议填写你反代后的最终访问地址,例如 `https://sub.example.com`
- `AIRPORT_A_URL` / `AIRPORT_B_URL` 都可以直接填订阅地址,项目会自动判断是 YAML 还是 URI 订阅
- `AIRPORT_A_URL` / `AIRPORT_B_URL` / `AIRPORT_C_URL` 都可以直接填订阅地址,项目会自动判断是 YAML 还是 URI 订阅
- 也可以直接填本地文件路径,例如 `/app/data/sources/airport-b.txt``file:///app/data/sources/airport-b.txt`
- 允许把其中一个留空;留空时这个机场会自动跳过
@@ -85,15 +85,15 @@ docker compose up -d --build
- 单 provider
`https://YOUR_DOMAIN/<PUBLIC_PATH>/providers/airport-a.yaml`
- merged provider
`https://YOUR_DOMAIN/<PUBLIC_PATH>/providers/merged.yaml?sources=airport-a,airport-b`
`https://YOUR_DOMAIN/<PUBLIC_PATH>/providers/merged.yaml?sources=airport-a,airport-b,airport-c`
- Mihomo/OpenClash 薄壳入口:
`https://YOUR_DOMAIN/<PUBLIC_PATH>/clients/mihomo.yaml?sources=airport-a,airport-b`
`https://YOUR_DOMAIN/<PUBLIC_PATH>/clients/mihomo.yaml?sources=airport-a,airport-b,airport-c`
- Stash 薄壳入口:
`https://YOUR_DOMAIN/<PUBLIC_PATH>/clients/stash.yaml?sources=airport-a,airport-b`
`https://YOUR_DOMAIN/<PUBLIC_PATH>/clients/stash.yaml?sources=airport-a,airport-b,airport-c`
- Mihomo/OpenClash bundle
`https://YOUR_DOMAIN/<PUBLIC_PATH>/bundle/mihomo.yaml?sources=airport-a,airport-b`
`https://YOUR_DOMAIN/<PUBLIC_PATH>/bundle/mihomo.yaml?sources=airport-a,airport-b,airport-c`
- Stash bundle
`https://YOUR_DOMAIN/<PUBLIC_PATH>/bundle/stash.yaml?sources=airport-a,airport-b`
`https://YOUR_DOMAIN/<PUBLIC_PATH>/bundle/stash.yaml?sources=airport-a,airport-b,airport-c`
---
@@ -111,8 +111,8 @@ HEAD /<PUBLIC_PATH>/providers/{name}.yaml
### 2. merged provider
```text
GET /<PUBLIC_PATH>/providers/merged.yaml?sources=airport-a,airport-b
HEAD /<PUBLIC_PATH>/providers/merged.yaml?sources=airport-a,airport-b
GET /<PUBLIC_PATH>/providers/merged.yaml?sources=airport-a,airport-b,airport-c
HEAD /<PUBLIC_PATH>/providers/merged.yaml?sources=airport-a,airport-b,airport-c
```
把多个 provider 合并成一个 `proxies:` 文件返回。响应头只取 `sources` 参数里**第一个源**的配额信息。
@@ -120,10 +120,10 @@ HEAD /<PUBLIC_PATH>/providers/merged.yaml?sources=airport-a,airport-b
### 3. 薄壳客户端配置
```text
GET /<PUBLIC_PATH>/clients/mihomo.yaml?sources=airport-a,airport-b
GET /<PUBLIC_PATH>/clients/stash.yaml?sources=airport-a,airport-b
HEAD /<PUBLIC_PATH>/clients/mihomo.yaml?sources=airport-a,airport-b
HEAD /<PUBLIC_PATH>/clients/stash.yaml?sources=airport-a,airport-b
GET /<PUBLIC_PATH>/clients/mihomo.yaml?sources=airport-a,airport-b,airport-c
GET /<PUBLIC_PATH>/clients/stash.yaml?sources=airport-a,airport-b,airport-c
HEAD /<PUBLIC_PATH>/clients/mihomo.yaml?sources=airport-a,airport-b,airport-c
HEAD /<PUBLIC_PATH>/clients/stash.yaml?sources=airport-a,airport-b,airport-c
```
特点:
@@ -136,10 +136,10 @@ HEAD /<PUBLIC_PATH>/clients/stash.yaml?sources=airport-a,airport-b
### 4. bundle 单文件配置
```text
GET /<PUBLIC_PATH>/bundle/mihomo.yaml?sources=airport-a,airport-b
GET /<PUBLIC_PATH>/bundle/stash.yaml?sources=airport-a,airport-b
HEAD /<PUBLIC_PATH>/bundle/mihomo.yaml?sources=airport-a,airport-b
HEAD /<PUBLIC_PATH>/bundle/stash.yaml?sources=airport-a,airport-b
GET /<PUBLIC_PATH>/bundle/mihomo.yaml?sources=airport-a,airport-b,airport-c
GET /<PUBLIC_PATH>/bundle/stash.yaml?sources=airport-a,airport-b,airport-c
HEAD /<PUBLIC_PATH>/bundle/mihomo.yaml?sources=airport-a,airport-b,airport-c
HEAD /<PUBLIC_PATH>/bundle/stash.yaml?sources=airport-a,airport-b,airport-c
```
特点: