Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

为 1.8.7 的版本更新补充了一些文档的内容 #459

Merged
merged 6 commits into from
Jan 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions docs/config/outbounds/wireguard.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,11 @@ Xray-core v1.8.0 - v1.8.4 没有 `"domainStrategy"`。<br>
URL:端口 格式,例如 `engage.cloudflareclient.com:2408`<br>
IP:端口 格式,例如 `162.159.192.1:2408` 或 `[2606:4700:d0::a29f:c001]:2408`

::: tip
当目标地址类型为 URL 时,将使用 Xray-core 内置 DNS 查询 URL 以获取 IP,IPv4 或 IPv6 优先级由 `domainStrategy` 的值控制。<br>
若没写 `"dns"` 配置,使用系统 DNS 查询 URL 以获取 IP,IPv4 或 IPv6 优先级由系统控制。
:::

> `publicKey`: string

服务器公钥,用于验证, 必填
Expand Down
58 changes: 56 additions & 2 deletions docs/config/routing.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,10 @@
> `type`: "field"

目前只支持`"field"`这一个选项。
Xray-core v1.8.7 前必填,v1.8.7 后可省略该行。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

没加tip是觉得tip太多有点乱()


::: tip
Xray-core v1.8.7 或更高版本可省略该行。
:::

> `domain`: \[string\]

Expand Down Expand Up @@ -188,7 +191,10 @@ Xray-core v1.8.7 前必填,v1.8.7 后可省略该行。
```json
{
"tag": "balancer",
"selector": []
"selector": [],
"strategy": {
"type":"roundRobin"
}
}
```

Expand All @@ -202,6 +208,54 @@ Xray-core v1.8.7 前必填,v1.8.7 后可省略该行。

如果匹配到多个 outbound,负载均衡器目前会从中随机选出一个作为最终的 outbound。

> `strategy`: \[ string \]

`"type":"roundRobin"` 表示按顺序选择匹配到的 outbounds tag,若不写 `"strategy"` 字段表示随机选择匹配到的 outbounds tag。

配置示例:

```json
"routing": {
"rules": [
{
"inboundTag": [
"in"
],
"balancerTag": "round"
}
],
"balancers" : [
{
"selector": [
"out"
],
"strategy": {
"type":"roundRobin"
},
"tag": "round"
}
]
}

"inbounds": [
{
// 入站配置
"tag": "in"
}
]

"outbounds": [
{
// 出站配置
"tag": "out1"
},
{
// 出站配置
"tag": "out2"
}
]
```

### 预定义域名列表

此列表预置于每一个 Xray 的安装包中,文件名为 `geosite.dat`。这个文件包含了一些常见的域名,使用方式:`geosite:filename`,如 `geosite:google` 表示对文件内符合 `google` 内包含的域名,进行路由筛选或 DNS 筛选。
Expand Down
5 changes: 3 additions & 2 deletions docs/config/transport.md
Original file line number Diff line number Diff line change
Expand Up @@ -686,8 +686,9 @@ TCP 拥塞控制算法。仅支持 Linux。

> `interface`: ""

指定绑定出口网卡名称,支持 linux / iOS / Mac OS。<br>
iOS / Mac OS 需要 Xray-core v1.8.6 或更高版本。
指定绑定出口网卡名称,支持 linux / iOS / Mac OS / Windows。<br>
iOS / Mac OS 需要 Xray-core v1.8.6 或更高版本。<br>
Windows 需要 Xray-core v1.8.7 或更高版本。

> `V6Only`: true | false

Expand Down
8 changes: 7 additions & 1 deletion docs/document/command.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Xray 使用 Go 风格的命令及参数

## 获取基本命令

您可以运行 `xray help` 来获得所有 xray 最基础的用法, 以及可用的命令及说明.
您可以运行 `xray help` 来获得所有 xray 最基础的用法, 以及可用的命令及说明

```
Xray is a platform for building proxies.
Expand Down Expand Up @@ -58,6 +58,12 @@ without launching the server
配置文件除了默认的 JSON 格式外,也可以使用 TOML 和 YAML。在不指定格式的前提下会通过文件扩展名识别。
:::

```
xray run -dump
```

用以输出多文件配置融合之后的结果。

### xray version

输出 Xray 版本、 Golang 版本等信息。
Expand Down
Loading