Merge branch 'XTLS:main' into ru

pull/529/head
Nikita Korotaev 2024-07-16 16:54:29 +05:00 committed by GitHub
commit 2785ca7851
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
8 changed files with 127 additions and 3 deletions

View File

@ -3,6 +3,9 @@ on:
push:
branches:
- main
pull_request:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
@ -36,6 +39,7 @@ jobs:
pnpm install
yarn docs:build
- name: Deploy
if: github.event_name != 'pull_request'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
@ -47,6 +51,7 @@ jobs:
run: |
yarn docs:build
- name: Deploy to main Repository
if: github.event_name != 'pull_request'
uses: peaceiris/actions-gh-pages@v3
with:
personal_token: ${{ secrets.ACTION_PERSONAL_TOKEN }}

View File

@ -10,6 +10,7 @@ import process from 'node:process'
// import { getDirname, path } from '@vuepress/utils'
import { getDirname, path } from 'vuepress/utils'
import { MermaidPlugin } from './plugins/mermaid/node/mermaid'
import i18nPlugin from "vuepress-plugin-i18n";
const __dirname = getDirname(import.meta.url)
console.log('>>> __dirname -> ', __dirname)
@ -25,6 +26,21 @@ console.log(
export default defineUserConfig(<UserConfig>{
plugins: [
i18nPlugin({
updatedTime: "git",
translationGuide: "https://github.com/XTLS/Xray-docs-next",
locales: {
en: {
lang: "en-US",
untranslated: {
title: "Untranslated"
},
outdated: {
title: "Outdated"
}
}
}
}),
searchPlugin({
locales: {
"/": {

View File

@ -28,6 +28,7 @@ export const sidebarEn: SidebarConfig = {
'/en/config/stats.md',
'/en/config/transport.md',
'/en/config/metrics.md',
'/en/config/observatory.md',
],
},
{

View File

@ -22,7 +22,9 @@ The configuration file of Xray is in JSON format, and the configuration format f
"stats": {},
"reverse": {},
"fakedns": {},
"metrics": {}
"metrics": {},
"observatory": {},
"burstObservatory": {}
}
```
@ -78,4 +80,12 @@ FakeDNS configuration. Can be used with a transparent proxy to obtain the actual
> metrics: [metricsObject](./metrics.md)
Metrics configuration. A more straightforward (and hopefully better) way to export metrics.
Metrics configuration. A more straightforward (and hopefully better) way to export metrics.
> observatory: [ObservatoryObject](./observatory.md#observatoryobject)
Background connection observation. Detect the connection status of outbound proxies.
> burstObservatory: [BurstObservatoryObject](./observatory.md#burstobservatoryobject)
Concurrent connection observation. Detect the connection status of outbound proxies.

View File

@ -7,7 +7,7 @@ The interface can be enabled through the api configuration module. When the api
Please refer to the [related configuration](#related-configuration) in this section.
::: warning
Most users do not need to use this API. Novices can ignore this item directly.
Most users do not need to use this API. Novices can ignore this page entirely.
:::
## ApiObject
@ -18,6 +18,7 @@ Most users do not need to use this API. Novices can ignore this item directly.
{
"api": {
"tag": "api",
"listen": "127.0.0.1:8080",
"services": ["HandlerService", "LoggerService", "StatsService"]
}
}
@ -27,6 +28,13 @@ Most users do not need to use this API. Novices can ignore this item directly.
Outbound proxy identifier.
> `listen`: string
The IP and port that the API service listens on. This is an optional configuration item.
When you omit this item, you need to add inbounds and routing configurations according to the examples in the [relevant configurations below](#related-configuration).
> `services`: [string]
List of enabled APIs, optional values can be found in [Supported API List](#supported-api-list).
@ -65,6 +73,18 @@ Add routing rules for the api inbound in the routing configuration.
}
```
Add api to basic configuration
```
"api": {
"tag": "api",
"services": [
"StatsService"
]
}
```
## Supported API List
### HandlerService
@ -78,6 +98,18 @@ APIs that modify the inbound and outbound proxies, with the following available
- Add a user to an inbound proxy (VMess, VLESS, Trojan, and Shadowsocks(v1.3.0+) only);
- Delete a user from an inbound proxy (VMess, VLESS, Trojan, and Shadowsocks(v1.3.0+) only);
## RoutingService
API for adding, deleting, and replacing routing rules and querying equalizer statistics. The available functions are as follows:
* `adrules` adds and replaces routing configuration
* `rmrules` delete routing rules
* `sib` Disconnect source IP
* `bi` Query equalizer statistics
* `bo` Forces the equalizer to select the specified outboundTag
You can use something like `./xray help api bi` to query the specific usage.
### LoggerService
Supports restarting the built-in logger, which can be used in conjunction with logrotate to perform operations on log files.

View File

@ -112,3 +112,11 @@ Recommendations:
HTTP/1.1 with or without TLS, h2 and h2c, however no h3.
Neither Xray server nor client support h3, but this may change in the future.
## Browser Dialer
<Badge text="v1.8.17+" type="warning"/>
If uTLS is not enough, SplitHTTP's TLS can be handled by a browser using [Browser Dialer](../features/browser_dialer.md)
Depending on the browser, Browser Dialer also supports transmission of SplitHTTP using HTTP3 (QUIC) while the regular implementation does not.

View File

@ -13,6 +13,7 @@
"@vuepress/bundler-webpack": "2.0.0-rc.2",
"@vuepress/plugin-back-to-top": "^2.0.0-rc.3",
"@vuepress/plugin-search": "2.0.0-rc.3",
"vuepress-plugin-i18n": "https://github.com/XTLS/vuepress-plugin-i18n#5ae5b2d",
"postcss-loader": "^8.0.0",
"prettier": "^3.3.2",
"sass": "^1.51.0",

View File

@ -90,6 +90,9 @@ importers:
vuepress:
specifier: 2.0.0-rc.2
version: 2.0.0-rc.2(@vuepress/bundler-vite@2.0.0-rc.2(@types/node@20.14.9)(jiti@1.21.0)(sass@1.77.4)(terser@5.31.0)(typescript@5.5.2))(@vuepress/bundler-webpack@2.0.0-rc.2(esbuild@0.22.0)(typescript@5.5.2))(typescript@5.5.2)(vue@3.3.13(typescript@5.5.2))
vuepress-plugin-i18n:
specifier: https://github.com/XTLS/vuepress-plugin-i18n#5ae5b2d
version: https://codeload.github.com/XTLS/vuepress-plugin-i18n/tar.gz/5ae5b2d(typescript@5.5.2)(vuepress@2.0.0-rc.2(@vuepress/bundler-vite@2.0.0-rc.2(@types/node@20.14.9)(jiti@1.21.0)(sass@1.77.4)(terser@5.31.0)(typescript@5.5.2))(@vuepress/bundler-webpack@2.0.0-rc.2(esbuild@0.22.0)(typescript@5.5.2))(typescript@5.5.2)(vue@3.3.13(typescript@5.5.2)))
packages:
@ -3053,6 +3056,9 @@ packages:
resolution: {integrity: sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==}
engines: {node: '>=12'}
striptags@3.2.0:
resolution: {integrity: sha512-g45ZOGzHDMe2bdYMdIvdAfCQkCTDMGBazSw1ypMowwGIee7ZQ5dU0rBJ8Jqgl+jAKIv4dbeE1jscZq9wid1Tkw==}
style-loader@3.3.4:
resolution: {integrity: sha512-0WqXzrsMTyb8yjZJHDqwmnwRJvhALK9LfRtRc6B4UTWe8AijYLZYZ9thuJTZc2VfQWINADW/j+LiJnfy2RoC1w==}
engines: {node: '>= 12.13.0'}
@ -3305,6 +3311,18 @@ packages:
typescript:
optional: true
vuepress-plugin-i18n@https://codeload.github.com/XTLS/vuepress-plugin-i18n/tar.gz/5ae5b2d:
resolution: {tarball: https://codeload.github.com/XTLS/vuepress-plugin-i18n/tar.gz/5ae5b2d}
version: 0.8.4
peerDependencies:
vuepress: 2.0.0-rc.2
vuepress-shared@2.0.0-rc.15:
resolution: {integrity: sha512-PzuXgAlzTrD6b6pCaeSb65CD5ponpD86IF+xaCxWrQDAQWk4zSY2brPk6seS10i2teZFNqVeyY8ERoC27HOzcg==}
engines: {node: '>=18.16.0', npm: '>=8', pnpm: '>=7', yarn: '>=2'}
peerDependencies:
vuepress: 2.0.0-rc.2
vuepress@2.0.0-rc.2:
resolution: {integrity: sha512-OEHfXx4Q3IzkXqcY9bKZqHXYAnSR82AGrmWYX5R1I3+ntzjaAbUhUKbG/jjMzLg40XqAHS++pM/zzMBNrcY3rg==}
engines: {node: '>=18.16.0'}
@ -6790,6 +6808,8 @@ snapshots:
strip-final-newline@3.0.0: {}
striptags@3.2.0: {}
style-loader@3.3.4(webpack@5.91.0(esbuild@0.22.0)):
dependencies:
webpack: 5.91.0(esbuild@0.22.0)
@ -6990,6 +7010,37 @@ snapshots:
optionalDependencies:
typescript: 5.5.2
vuepress-plugin-i18n@https://codeload.github.com/XTLS/vuepress-plugin-i18n/tar.gz/5ae5b2d(typescript@5.5.2)(vuepress@2.0.0-rc.2(@vuepress/bundler-vite@2.0.0-rc.2(@types/node@20.14.9)(jiti@1.21.0)(sass@1.77.4)(terser@5.31.0)(typescript@5.5.2))(@vuepress/bundler-webpack@2.0.0-rc.2(esbuild@0.22.0)(typescript@5.5.2))(typescript@5.5.2)(vue@3.3.13(typescript@5.5.2))):
dependencies:
'@vuepress/client': 2.0.0-rc.2(typescript@5.5.2)
'@vuepress/core': 2.0.0-rc.2(typescript@5.5.2)
'@vuepress/utils': 2.0.0-rc.2
chokidar: 3.6.0
vue: 3.3.13(typescript@5.5.2)
vuepress: 2.0.0-rc.2(@vuepress/bundler-vite@2.0.0-rc.2(@types/node@20.14.9)(jiti@1.21.0)(sass@1.77.4)(terser@5.31.0)(typescript@5.5.2))(@vuepress/bundler-webpack@2.0.0-rc.2(esbuild@0.22.0)(typescript@5.5.2))(typescript@5.5.2)(vue@3.3.13(typescript@5.5.2))
vuepress-shared: 2.0.0-rc.15(typescript@5.5.2)(vuepress@2.0.0-rc.2(@vuepress/bundler-vite@2.0.0-rc.2(@types/node@20.14.9)(jiti@1.21.0)(sass@1.77.4)(terser@5.31.0)(typescript@5.5.2))(@vuepress/bundler-webpack@2.0.0-rc.2(esbuild@0.22.0)(typescript@5.5.2))(typescript@5.5.2)(vue@3.3.13(typescript@5.5.2)))
transitivePeerDependencies:
- '@vue/composition-api'
- supports-color
- typescript
vuepress-shared@2.0.0-rc.15(typescript@5.5.2)(vuepress@2.0.0-rc.2(@vuepress/bundler-vite@2.0.0-rc.2(@types/node@20.14.9)(jiti@1.21.0)(sass@1.77.4)(terser@5.31.0)(typescript@5.5.2))(@vuepress/bundler-webpack@2.0.0-rc.2(esbuild@0.22.0)(typescript@5.5.2))(typescript@5.5.2)(vue@3.3.13(typescript@5.5.2))):
dependencies:
'@vueuse/core': 10.11.0(vue@3.4.27(typescript@5.5.2))
cheerio: 1.0.0-rc.12
dayjs: 1.11.11
execa: 8.0.1
fflate: 0.8.2
gray-matter: 4.0.3
semver: 7.6.2
striptags: 3.2.0
vue: 3.4.27(typescript@5.5.2)
vue-router: 4.3.2(vue@3.4.27(typescript@5.5.2))
vuepress: 2.0.0-rc.2(@vuepress/bundler-vite@2.0.0-rc.2(@types/node@20.14.9)(jiti@1.21.0)(sass@1.77.4)(terser@5.31.0)(typescript@5.5.2))(@vuepress/bundler-webpack@2.0.0-rc.2(esbuild@0.22.0)(typescript@5.5.2))(typescript@5.5.2)(vue@3.3.13(typescript@5.5.2))
transitivePeerDependencies:
- '@vue/composition-api'
- typescript
vuepress@2.0.0-rc.2(@vuepress/bundler-vite@2.0.0-rc.2(@types/node@20.14.9)(jiti@1.21.0)(sass@1.77.4)(terser@5.31.0)(typescript@5.5.2))(@vuepress/bundler-webpack@2.0.0-rc.2(esbuild@0.22.0)(typescript@5.5.2))(typescript@5.5.2)(vue@3.3.13(typescript@5.5.2)):
dependencies:
'@vuepress/cli': 2.0.0-rc.2(typescript@5.5.2)