docs(wip): documentation for v2

This commit is contained in:
0xJacky 2024-01-15 23:49:32 +08:00
parent 712a4d2185
commit 2d52ada657
No known key found for this signature in database
GPG key ID: B6E4A6E4A561BAF0
16 changed files with 472 additions and 281 deletions

View file

@ -1,53 +1,54 @@
import {LocaleSpecificConfig, DefaultTheme} from "vitepress"
import {LocaleSpecificConfig, DefaultTheme} from 'vitepress'
import {demoUrl} from './common'
export const enConfig: LocaleSpecificConfig<DefaultTheme.Config> = {
themeConfig: {
nav: [
{text: 'Home', link: '/'},
{text: 'Guide', link: '/guide/about'},
{text: 'Demo', link: demoUrl}
],
themeConfig: {
nav: [
{text: 'Home', link: '/'},
{text: 'Guide', link: '/guide/about'},
{text: 'Demo', link: demoUrl}
],
sidebar: {
'/guide/': [
{
text: 'Introduction',
collapsed: false,
items: [
{text: 'What is Nginx UI?', link: '/guide/about'},
{text: 'Getting Started', link: '/guide/getting-started'},
{text: 'Install Script', link: '/guide/install-script-linux'}
]
},
{
text: 'Development',
collapsed: false,
items: [
{text: 'Build', link: '/guide/build'},
{text: 'Project Structure', link: '/guide/project-structure'},
{text: 'Config Template', link: '/guide/nginx-ui-template'},
{text: 'Contributing', link: '/guide/contributing'}
]
},
{
text: 'Configuration',
collapsed: false,
items: [
{text: 'Server', link: '/guide/config-server'},
{text: 'Nginx Log', link: '/guide/config-nginx-log'},
{text: 'Open AI', link: '/guide/config-openai'}
]
},
{
text: 'Appendix',
collapsed: false,
items: [
{text: 'Nginx Proxy Example', link: '/guide/nginx-proxy-example'},
{text: 'License', link: '/guide/license'}
]
}
],
sidebar: {
'/guide/': [
{
text: 'Introduction',
collapsed: false,
items: [
{text: 'What is Nginx UI?', link: '/guide/about'},
{text: 'Getting Started', link: '/guide/getting-started'},
{text: 'Install Script', link: '/guide/install-script-linux'}
]
},
{
text: 'Development',
collapsed: false,
items: [
{text: 'Build', link: '/guide/build'},
{text: 'Project Structure', link: '/guide/project-structure'},
{text: 'Config Template', link: '/guide/nginx-ui-template'},
{text: 'Contributing', link: '/guide/contributing'}
]
},
{
text: 'Configuration',
collapsed: false,
items: [
{text: 'Server', link: '/guide/config-server'},
{text: 'Nginx Log', link: '/guide/config-nginx'},
{text: 'Open AI', link: '/guide/config-openai'},
{text: 'Casdoor', link: '/guide/config-casdoor'}
]
},
{
text: 'Appendix',
collapsed: false,
items: [
{text: 'Nginx Proxy Example', link: '/guide/nginx-proxy-example'},
{text: 'License', link: '/guide/license'}
]
}
]
}
}
}

View file

@ -1,93 +1,97 @@
import {LocaleSpecificConfig, DefaultTheme} from "vitepress"
import {LocaleSpecificConfig, DefaultTheme} from 'vitepress'
import {demoUrl, editLinkPattern} from './common'
export const zhCNConfig: LocaleSpecificConfig<DefaultTheme.Config> = {
themeConfig: {
nav: [
{text: '首页', link: '/zh_CN/'},
{text: '手册', link: '/zh_CN/guide/about'},
{text: '演示', link: demoUrl}
],
themeConfig: {
nav: [
{text: '首页', link: '/zh_CN/'},
{text: '手册', link: '/zh_CN/guide/about'},
{text: '演示', link: demoUrl}
],
editLink: {
text: '编辑此页',
pattern: editLinkPattern
editLink: {
text: '编辑此页',
pattern: editLinkPattern
},
sidebar: {
'/zh_CN/guide/': [
{
text: '介绍',
collapsed: false,
items: [
{text: '何为 Nginx UI?', link: '/zh_CN/guide/about'},
{text: '即刻开始', link: '/zh_CN/guide/getting-started'},
{text: '安装脚本', link: '/zh_CN/guide/install-script-linux'}
]
},
sidebar: {
'/zh_CN/guide/': [
{
text: '介绍',
collapsed: false,
items: [
{text: '何为 Nginx UI?', link: '/zh_CN/guide/about'},
{text: '即刻开始', link: '/zh_CN/guide/getting-started'},
{text: '安装脚本', link: '/zh_CN/guide/install-script-linux'}
]
},
{
text: '开发',
collapsed: false,
items: [
{text: '构建', link: '/zh_CN/guide/build'},
{text: '项目结构', link: '/zh_CN/guide/project-structure'},
{text: '配置模板', link: '/zh_CN/guide/nginx-ui-template'},
{text: '贡献代码', link: '/zh_CN/guide/contributing'}
]
},
{
text: '配置',
collapsed: false,
items: [
{text: '服务端', link: '/zh_CN/guide/config-server'},
{text: 'Nginx 日志', link: '/zh_CN/guide/config-nginx-log'},
{text: 'Open AI', link: '/zh_CN/guide/config-openai'}
]
},
{
text: '附录',
collapsed: false,
items: [
{text: 'Nginx 代理示例', link: '/zh_CN/guide/nginx-proxy-example'},
{text: '开源协议', link: '/zh_CN/guide/license'}
]
}
]
{
text: '开发',
collapsed: false,
items: [
{text: '构建', link: '/zh_CN/guide/build'},
{text: '项目结构', link: '/zh_CN/guide/project-structure'},
{text: '配置模板', link: '/zh_CN/guide/nginx-ui-template'},
{text: '贡献代码', link: '/zh_CN/guide/contributing'}
]
},
docFooter: {
prev: '上一页',
next: '下一页',
{
text: '配置',
collapsed: false,
items: [
{text: '服务端', link: '/zh_CN/guide/config-server'},
{text: 'Nginx', link: '/zh_CN/guide/config-nginx'},
{text: 'Open AI', link: '/zh_CN/guide/config-openai'},
{text: 'Casdoor', link: '/zh_CN/guide/config-casdoor'}
]
},
returnToTopLabel: '返回顶部',
outlineTitle: '导航栏',
darkModeSwitchLabel: '外观',
sidebarMenuLabel: '归档',
lastUpdatedText: '更新于',
search: {
provider: 'local',
options: {
locales: {
zh_CN: {
translations: {
button: {
buttonText: '搜索文档',
buttonAriaLabel: '搜索文档'
},
modal: {
noResultsText: '无法找到相关结果',
resetButtonTitle: '清除查询条件',
footer: {
selectText: '选择',
navigateText: '切换',
closeText: '关闭'
}
}
}
}
}
}
{
text: '附录',
collapsed: false,
items: [
{text: 'Nginx 代理示例', link: '/zh_CN/guide/nginx-proxy-example'},
{text: '开源协议', link: '/zh_CN/guide/license'}
]
}
]
},
docFooter: {
prev: '上一页',
next: '下一页'
},
returnToTopLabel: '返回顶部',
outline: {
label: '导航栏'
},
darkModeSwitchLabel: '外观',
sidebarMenuLabel: '归档',
lastUpdated: {
text: '更新于'
},
search: {
provider: 'local',
options: {
locales: {
zh_CN: {
translations: {
button: {
buttonText: '搜索文档',
buttonAriaLabel: '搜索文档'
},
modal: {
noResultsText: '无法找到相关结果',
resetButtonTitle: '清除查询条件',
footer: {
selectText: '选择',
navigateText: '切换',
closeText: '关闭'
}
}
}
}
}
}
}
}
}

View file

@ -1,92 +1,97 @@
import {LocaleSpecificConfig, DefaultTheme} from "vitepress"
import {LocaleSpecificConfig, DefaultTheme} from 'vitepress'
import {demoUrl, editLinkPattern} from './common'
export const zhTWConfig: LocaleSpecificConfig<DefaultTheme.Config> = {
themeConfig: {
nav: [
{text: '首頁', link: '/zh_TW/'},
{text: '手冊', link: '/zh_TW/guide/about'},
{text: '演示', link: demoUrl}
],
themeConfig: {
nav: [
{text: '首頁', link: '/zh_TW/'},
{text: '手冊', link: '/zh_TW/guide/about'},
{text: '演示', link: demoUrl}
],
editLink: {
text: '編輯此頁',
pattern: editLinkPattern
editLink: {
text: '編輯此頁',
pattern: editLinkPattern
},
sidebar: {
'/zh_TW/guide/': [
{
text: '介紹',
collapsed: false,
items: [
{text: '何為 Nginx UI?', link: '/zh_TW/guide/about'},
{text: '即刻開始', link: '/zh_TW/guide/getting-started'},
{text: '安裝指令碼', link: '/zh_TW/guide/install-script-linux'}
]
},
sidebar: {
'/zh_TW/guide/': [
{
text: '介紹',
collapsed: false,
items: [
{text: '何為 Nginx UI?', link: '/zh_TW/guide/about'},
{text: '即刻開始', link: '/zh_TW/guide/getting-started'},
{text: '安裝指令碼', link: '/zh_TW/guide/install-script-linux'}
]
},
{
text: '開發',
collapsed: false,
items: [
{text: '構建', link: '/zh_TW/guide/build'},
{text: '專案結構', link: '/zh_TW/guide/project-structure'},
{text: '貢獻程式碼', link: '/zh_TW/guide/contributing'}
]
},
{
text: '配置',
collapsed: false,
items: [
{text: '服務端', link: '/zh_TW/guide/config-server'},
{text: 'Nginx 日誌', link: '/zh_TW/guide/config-nginx-log'},
{text: 'Open AI', link: '/zh_TW/guide/config-openai'}
]
},
{
text: '附錄',
collapsed: false,
items: [
{text: 'Nginx 代理示例', link: '/zh_TW/guide/nginx-proxy-example'},
{text: '開源協議', link: '/zh_TW/guide/license'}
]
}
]
{
text: '開發',
collapsed: false,
items: [
{text: '構建', link: '/zh_TW/guide/build'},
{text: '專案結構', link: '/zh_TW/guide/project-structure'},
{text: '貢獻程式碼', link: '/zh_TW/guide/contributing'}
]
},
docFooter: {
prev: '上一頁',
next: '下一頁',
{
text: '配置',
collapsed: false,
items: [
{text: '服務端', link: '/zh_TW/guide/config-server'},
{text: 'Nginx 日誌', link: '/zh_TW/guide/config-nginx'},
{text: 'Open AI', link: '/zh_TW/guide/config-openai'},
{text: 'Casdoor', link: '/zh_TW/guide/config-casdoor'}
]
},
returnToTopLabel: '返回頂部',
outlineTitle: '導航欄',
darkModeSwitchLabel: '外觀',
sidebarMenuLabel: '歸檔',
lastUpdatedText: '更新於',
search: {
provider: 'local',
options: {
locales: {
zh_CN: {
translations: {
button: {
buttonText: '搜尋文件',
buttonAriaLabel: '搜尋文件'
},
modal: {
noResultsText: '無法找到相關結果',
resetButtonTitle: '清除查詢條件',
footer: {
selectText: '選擇',
navigateText: '切換',
closeText: '關閉'
}
}
}
}
}
}
{
text: '附錄',
collapsed: false,
items: [
{text: 'Nginx 代理示例', link: '/zh_TW/guide/nginx-proxy-example'},
{text: '開源協議', link: '/zh_TW/guide/license'}
]
}
]
},
docFooter: {
prev: '上一頁',
next: '下一頁'
},
returnToTopLabel: '返回頂部',
outline: {
label: '導航欄'
},
darkModeSwitchLabel: '外觀',
sidebarMenuLabel: '歸檔',
lastUpdated: {
text: '更新於'
},
search: {
provider: 'local',
options: {
locales: {
zh_CN: {
translations: {
button: {
buttonText: '搜尋文件',
buttonAriaLabel: '搜尋文件'
},
modal: {
noResultsText: '無法找到相關結果',
resetButtonTitle: '清除查詢條件',
footer: {
selectText: '選擇',
navigateText: '切換',
closeText: '關閉'
}
}
}
}
}
}
}
}
}

View file

@ -0,0 +1,39 @@
# Casdoor
本节介绍如何配置 Casdoor 作为 Nginx UI 的身份验证提供程序,该功能由 @Jraaay 贡献。
Casdoor 是一个强大的、全面的身份认证解决方案,支持 OAuth 2.0、SAML 2.0、LDAP、AD 和多种社交登录方式。通过集成 CasdoorNginx UI 可以利用这些功能来提升安全性和用户体验。
## Endpoint
- 类型:`string`
这是 Casdoor 服务器的 URL。您需要确保 Nginx UI 可以访问此 URL。
## ClientId
- 类型:`string`
这是 Casdoor 为您的应用生成的客户端 ID。它用于在身份验证过程中标识您的应用。
## ClientSecret
- 类型:`string`
这是 Casdoor 为您的应用生成的客户端密钥。它是保持您的应用安全所必需的。
## Certificate
- 类型:`string`
这是用于身份验证过程中的证书。确保它是有效和可信的。
## Organization
- 类型:`string`
这是您在 Casdoor 中设置的组织名称。Casdoor 将使用此信息来处理身份验证请求。
## Application
- 类型:`string`
这是您在 Casdoor 中创建的应用名称。
## RedirectUri
- 类型:`string`
这是用户在成功登录或授权后重定向到的 URI。它应与 Casdoor 应用配置中的重定向 URI 一致。

Binary file not shown.

Before

Width:  |  Height:  |  Size: 305 KiB

After

Width:  |  Height:  |  Size: 421 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 294 KiB

After

Width:  |  Height:  |  Size: 413 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 302 KiB

After

Width:  |  Height:  |  Size: 422 KiB

Before After
Before After

View file

@ -61,7 +61,7 @@ Nginx UI 是一个全新的 Nginx 网络管理界面,旨在简化 Nginx 服务
Nginx UI 可在以下平台中使用:
- Mac OS X 10.10 Yosemite 及之后版本amd64 / arm64
- macOS 11 Big Sur 及之后版本amd64 / arm64
- Linux 2.6.23 及之后版本x86 / amd64 / arm64 / armv5 / armv6 / armv7
- 包括但不限于 Debian 7 / 8、Ubuntu 12.04 / 14.04 及后续版本、CentOS 6 / 7、Arch Linux
- FreeBSD

View file

@ -5,8 +5,8 @@
## 依赖
- Make
- Golang 版本 1.20 或更高
- node.js 版本 18 或更高
- Golang 版本 1.21 或更高
- node.js 版本 21 或更高
你需要在构建项目之前执行以下命令更新浏览器列表数据库。
```shell

View file

@ -0,0 +1,39 @@
# Casdoor
本节介绍如何配置 Casdoor 作为 Nginx UI 的身份验证提供程序,该功能由 @Jraaay 贡献。
Casdoor 是一个强大的、全面的身份认证解决方案,支持 OAuth 2.0、SAML 2.0、LDAP、AD 和多种社交登录方式。通过集成 CasdoorNginx UI 可以利用这些功能来提升安全性和用户体验。
## Endpoint
- 类型:`string`
这是 Casdoor 服务器的 URL。您需要确保 Nginx UI 可以访问此 URL。
## ClientId
- 类型:`string`
这是 Casdoor 为您的应用生成的客户端 ID。它用于在身份验证过程中标识您的应用。
## ClientSecret
- 类型:`string`
这是 Casdoor 为您的应用生成的客户端密钥。它是保持您的应用安全所必需的。
## Certificate
- 类型:`string`
这是用于身份验证过程中的证书。确保它是有效和可信的。
## Organization
- 类型:`string`
这是您在 Casdoor 中设置的组织名称。Casdoor 将使用此信息来处理身份验证请求。
## Application
- 类型:`string`
这是您在 Casdoor 中创建的应用名称。
## RedirectUri
- 类型:`string`
这是用户在成功登录或授权后重定向到的 URI。它应与 Casdoor 应用配置中的重定向 URI 一致。

View file

@ -1,46 +0,0 @@
# Nginx 日志
Nginx 日志对于监控、排查问题和维护您的 Web 服务器至关重要。它们提供了有关服务器性能、用户行为和潜在问题的宝贵见解。在本节中,我们将讨论两种主要类型的日志:访问日志和错误日志。
对于从 v1.5.2 或更早版本升级的 Nginx-UI Docker 用户,在配置 `app.ini` 之前,至关重要的是在您的 `nginx.conf`
中添加单独的 `access_log``error_log` 指令。
在 Nginx-UI 容器中,`/var/log/nginx/access.log` 是一个指向 `/dev/stdout` 的符号链接,而 `/var/log/nginx/error.log`
是一个指向 `/dev/stderr` 的符号链接。这种设置允许您使用 `docker logs nginx-ui` 命令查看 Nginx 和 Nginx-UI 日志。然而,这两个设备不支持
`tail` 命令,因此有必要使用额外的日志文件来记录 Nginx 日志。
示例:
```nginx
error_log /var/log/nginx/error.log notice;
error_log /var/log/nginx/error.local.log notice;
http {
...
access_log /var/log/nginx/access.log main;
access_log /var/log/nginx/access.local.log main;
...
}
```
此外,在 `app.ini` 中设置 nginx 访问日志和错误日志路径,然后重新启动 nginx-ui。
示例:
```ini
[nginx_log]
AccessLogPath = /var/log/nginx/access.local.log
ErrorLogPath = /var/log/nginx/error.local.log
```
## AccessLogPath
- 类型:`string`
此选项用于为 Nginx UI 设置 Nginx 访问日志的路径,以便我们在线查看日志内容。
## ErrorLogPath
- 类型:`string`
此选项用于为 Nginx UI 设置 Nginx 错误日志的路径,以便我们在线查看日志内容。

View file

@ -0,0 +1,130 @@
# Nginx
在本节中,我们将会介绍 Nginx UI 中关于 Nginx 控制命令、日志路径等参数的配置选项。
::: tip 提示
自 v2.0.0-beta.3 版本起,我们将 `nginx_log` 配置项改名为 `nginx`
:::
## 日志
Nginx 日志对于监控、排查问题和维护您的 Web 服务器至关重要。它们提供了有关服务器性能、用户行为和潜在问题的宝贵见解。
在本节中,我们将讨论两种主要类型的日志:访问日志和错误日志。
对于从 v1.5.2 或更早版本升级的 Nginx-UI Docker 用户,在配置 `app.ini` 之前,您需要在 `nginx.conf`
中添加单独的 `access_log``error_log` 指令。
在 Nginx-UI 容器中,`/var/log/nginx/access.log` 是一个指向 `/dev/stdout` 的符号链接,而 `/var/log/nginx/error.log`
是一个指向 `/dev/stderr` 的符号链接。这种设置允许您使用 `docker logs nginx-ui` 命令查看 Nginx 和 Nginx-UI 日志。然而,这两个设备不支持
`tail` 命令,因此有必要使用额外的日志文件来记录 Nginx 日志。
示例:
```nginx
error_log /var/log/nginx/error.log notice;
error_log /var/log/nginx/error.local.log notice;
http {
...
access_log /var/log/nginx/access.log main;
access_log /var/log/nginx/access.local.log main;
...
}
```
之后,请在 `app.ini` 中设置 nginx 访问日志和错误日志路径,然后重新启动 nginx-ui。
示例:
```ini
[nginx_log]
AccessLogPath = /var/log/nginx/access.local.log
ErrorLogPath = /var/log/nginx/error.local.log
```
### AccessLogPath
- 类型:`string`
此选项用于为 Nginx UI 设置 Nginx 访问日志的路径,以便我们在线查看日志内容。
::: tip 提示
在 v2 版本中,我们会读取 `nginx -V` 命令的输出,以获取 Nginx 访问日志的默认路径。
如果您需要设置不同的路径,您可以使用此选项。
:::
### ErrorLogPath
- 类型:`string`
此选项用于为 Nginx UI 设置 Nginx 错误日志的路径,以便我们在线查看日志内容。
::: tip 提示
在 v2 版本中,我们会读取 `nginx -V` 命令的输出,以获取 Nginx 错误日志的默认路径。
如果您需要设置不同的路径,您可以使用此选项。
:::
## 服务监控与控制
在本节中,我们将会介绍 Nginx UI 中关于 Nginx 服务的监控和控制命令的配置选项。
### ConfigDir
- 类型:`string`
此选项用于设置 Nginx 配置文件夹的路径。
在 v2 版本中,我们会读取 `nginx -V` 命令的输出,以获取 Nginx 配置文件的默认路径。
如果您需要覆盖默认路径,您可以使用此选项。
### PIDPath
- 类型:`string`
此选项用于设置 Nginx PID 文件的路径。Nginx UI 将通过判断该文件是否存在来判断 Nginx 服务的运行状态。
在 v2 版本中,我们会读取 `nginx -V` 命令的输出,以获取 Nginx PID 文件的默认路径。
如果您需要覆盖默认路径,您可以使用此选项。
### TestConfigCmd
- 类型:`string`
- 默认值:`nginx -t`
此选项用于设置 Nginx 测试配置的命令。
### ReloadCmd
- 类型:`string`
- 默认值:`nginx -s reload`
此选项用于设置 Nginx 重新加载配置的命令。
### RestartCmd
- 类型:`string`
::: tip 提示
我们建议使用 systemd 管理 Nginx 的用户,将这个值设置为 `systemctl restart nginx`
否则,当您在 Nginx UI 中重启 Nginx 后,将无法在 systemctl 中获取 Nginx 的准确状态。
:::
若此选项为空,则 Nginx UI 将使用以下命令关闭 Nginx 服务:
```bash
start-stop-daemon --stop --quiet --oknodo --retry=TERM/30/KILL/5 --pidfile $PID
```
若无法从 `nginx -V` 中获得 `--sbin-path` 路径,则 Nginx UI 将使用以下命令启动 Nginx 服务:
```bash
nginx
```
若可以获取到 `--sbin-path` 路径,则 Nginx UI 将使用以下命令启动 Nginx 服务:
```bash
start-stop-daemon --start --quiet --pidfile $PID --exec $SBIN_PATH
```

View file

@ -1,6 +1,12 @@
# 服务端
Nginx UI 配置的服务端部分涉及控制 Nginx UI 服务器的各种设置。在本节中,我们将讨论可用的选项、它们的默认值以及它们的目的。
Nginx UI 配置的服务端部分涉及控制 Nginx UI 服务器的各种设置。在页面中,我们将讨论可用的选项、它们的默认值以及它们的目的。
## HttpHost
- 类型: `string`
- 默认值:`0.0.0.0`
Nginx UI 服务器监听的主机名。此选项用于配置 Nginx UI 服务器监听传入 HTTP 请求的主机名。 更改默认主机名可能有助于提升安全性。
## HttpPort
@ -13,10 +19,24 @@ Nginx UI 服务器监听端口。此选项用于配置 Nginx UI 服务器监听
- 类型:`string`
- 支持的值:`release``debug`
- 默认值:`debug`
::: tip 提示
目前,我们尚未适应此选项,在使用方面,`release``debug` 之间不会有显著差异。
:::
此选项用于配置 Nginx UI 服务器的运行模式,主要影响日志打印的级别。
Nginx UI 的日志分为 6 个级别,分别为 `Debug``Info``Warn``Error``Panic``Fatal`,这些日志级别按照严重程度递增,
当使用 `debug` 模式时Nginx UI 将在控制台打印 SQL 及其执行的时间和调用者,`Debug` 级别或更高等级的日志也会被打印。
当使用 `release` 模式时Nginx UI 将不会在控制台打印 SQL 的执行时间和调用者, 只有 `Info` 级别或更高等级的日志才会被打印。
## JwtSecret
- 类型:`string`
此选项用于配置 Nginx UI 服务器用于生成 JWT 的密钥。
JWT 是一种用于验证用户身份的标准,它可以在用户登录后生成一个 token然后在后续的请求中使用该 token 来验证用户身份。
如果您使用一键安装脚本来部署 Nginx UI脚本将会生成一个 UUID 值并将它设置为此选项的值。
## HTTPChallengePort
@ -26,6 +46,11 @@ Nginx UI 服务器监听端口。此选项用于配置 Nginx UI 服务器监听
在获取 Let's Encrypt 证书时,此选项用于在 HTTP01 挑战模式中设置后端监听端口。HTTP01 挑战是 Let's Encrypt
用于验证您控制请求证书的域的域验证方法。
## Email
- 类型:`string`
在获取 Let's Encrypt 证书时此选项用于设置您的电子邮件地址。Let's Encrypt 会将您的电子邮件地址用于通知您证书的到期时间。
## Database
- 类型:`string`
@ -48,7 +73,7 @@ Nginx UI 服务器监听端口。此选项用于配置 Nginx UI 服务器监听
## PageSize
- 类型:`int`
- 默认值:10
- 默认值:`10`
此选项用于设置 Nginx UI 中列表分页的页面大小。调整页面大小有助于更有效地管理大量数据,但是过大的数量可能会增加服务器的压力。

View file

@ -6,8 +6,7 @@
.
├─ docs # 文档目录
├─ cmd # 命令行工具
├─ app # 使用 Vue 3 构建的前端
├─ server # 使用 Golang 构建的后端
├─ app # 使用 Vue 3 构建的前端
├─ resources # 其他资源,不参与构建
├─ template # 用于 Nginx 的模板文件
├─ app.example.ini # 配置文件的示例
@ -48,8 +47,7 @@
│ │ ├─ routes # Vue 路由
│ │ ├─ views # Vue 视图
│ │ ├─ gettext.ts # 定义翻译
│ │ ├─ style.less # 全局样式,使用 less 语法
│ │ ├─ dark.less # 暗黑主题样式,使用 less 语法
│ │ ├─ style.css # 引入 tailwind
│ │ └─ ...
│ └─ ...
└─ ...
@ -59,18 +57,14 @@
```
.
├─ server
│ ├─ internal # 内部包
│ │ └─ ...
│ ├─ api # 向前端提供的 API
│ ├─ model # 自动生成的模型
│ ├─ query # gen 自动生成的数据库请求文件
│ ├─ router # 路由和中间件
│ ├─ service # 服务文件
│ ├─ settings # 配置接口
│ ├─ test # 单元测试
│ └─ ...
├─ main.go # 后端入口
├─ internal # 内部包
├─ api # 向前端提供的 API
├─ model # 自动生成的模型
├─ query # gen 自动生成的数据库请求文件
├─ router # 路由和中间件
├─ settings # 配置接口
├─ test # 单元测试
├─ main.go # 主程序入口
└─ ...
```