Skip to content

Commit

Permalink
docs: update docs regarding to settings v2
Browse files Browse the repository at this point in the history
  • Loading branch information
0xJacky committed Oct 22, 2024
1 parent 6003414 commit 80cb8e1
Show file tree
Hide file tree
Showing 39 changed files with 1,063 additions and 304 deletions.
2 changes: 1 addition & 1 deletion api/system/install.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func InstallNginxUI(c *gin.Context) {
settings.NodeSettings.Secret = uuid.New().String()
settings.CertSettings.Email = json.Email
if "" != json.Database {
cSettings.DataBaseSettings.Name = json.Database
settings.DatabaseSettings.Name = json.Database
}

err := settings.Save()
Expand Down
14 changes: 10 additions & 4 deletions docs/.vitepress/config/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,20 @@ export const enConfig: LocaleSpecificConfig<DefaultTheme.Config> = {
text: 'Configuration',
collapsed: false,
items: [
{text: 'App', link: '/guide/config-app'},
{text: 'Server', link: '/guide/config-server'},
{text: 'Nginx', link: '/guide/config-nginx'},
{text: 'Open AI', link: '/guide/config-openai'},
{text: 'Database', link: '/guide/config-database'},
{text: 'Auth', link: '/guide/config-auth'},
{text: 'Casdoor', link: '/guide/config-casdoor'},
{text: 'Logrotate', link: '/guide/config-logrotate'},
{text: 'Cert', link: '/guide/config-cert'},
{text: 'Cluster', link: '/guide/config-cluster'},
{text: 'Auth', link: '/guide/config-auth'},
{text: 'Crypto', link: '/guide/config-crypto'},
{text: 'Http', link: '/guide/config-http'},
{text: 'Logrotate', link: '/guide/config-logrotate'},
{text: 'Nginx', link: '/guide/config-nginx'},
{text: 'Node', link: '/guide/config-node'},
{text: 'Open AI', link: '/guide/config-openai'},
{text: 'Terminal', link: '/guide/config-terminal'},
{text: 'Webauthn', link: '/guide/config-webauthn'}
]
},
Expand Down
20 changes: 13 additions & 7 deletions docs/.vitepress/config/zh_CN.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,21 @@ export const zhCNConfig: LocaleSpecificConfig<DefaultTheme.Config> = {
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: 'App', link: '/zh_CN/guide/config-app'},
{text: 'Server', link: '/zh_CN/guide/config-server'},
{text: 'Database', link: '/zh_CN/guide/config-database'},
{text: 'Auth', link: '/zh_CN/guide/config-auth'},
{text: 'Casdoor', link: '/zh_CN/guide/config-casdoor'},
{text: 'Cert', link: '/zh_CN/guide/config-cert'},
{text: 'Cluster', link: '/zh_CN/guide/config-cluster'},
{text: 'Crypto', link: '/zh_CN/guide/config-crypto'},
{text: 'Http', link: '/zh_CN/guide/config-http'},
{text: 'Logrotate', link: '/zh_CN/guide/config-logrotate'},
{text: '集群', link: '/zh_CN/guide/config-cluster'},
{text: '认证', link: '/zh_CN/guide/config-auth'},
{text: '加密', link: '/zh_CN/guide/config-crypto'},
{text: 'Webauthn', link: '/zh_CN/guide/config-webauthn'},
{text: 'Nginx', link: '/zh_CN/guide/config-nginx'},
{text: 'Node', link: '/zh_CN/guide/config-node'},
{text: 'Open AI', link: '/zh_CN/guide/config-openai'},
{text: 'Terminal', link: '/zh_CN/guide/config-terminal'},
{text: 'Webauthn', link: '/zh_CN/guide/config-webauthn'}
]
},
{
Expand Down
20 changes: 13 additions & 7 deletions docs/.vitepress/config/zh_TW.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,21 @@ export const zhTWConfig: LocaleSpecificConfig<DefaultTheme.Config> = {
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: 'App', link: '/zh_TW/guide/config-app'},
{text: 'Server', link: '/zh_TW/guide/config-server'},
{text: 'Database', link: '/zh_TW/guide/config-database'},
{text: 'Auth', link: '/zh_TW/guide/config-auth'},
{text: 'Casdoor', link: '/zh_TW/guide/config-casdoor'},
{text: 'Cert', link: '/zh_TW/guide/config-cert'},
{text: 'Cluster', link: '/zh_TW/guide/config-cluster'},
{text: 'Crypto', link: '/zh_TW/guide/config-crypto'},
{text: 'Http', link: '/zh_TW/guide/config-http'},
{text: 'Logrotate', link: '/zh_TW/guide/config-logrotate'},
{text: '集群', link: '/zh_TW/guide/config-cluster'},
{text: '認證', link: '/zh_TW/guide/config-auth'},
{text: '加密', link: '/zh_TW/guide/config-crypto'},
{text: 'Webauthn', link: '/zh_TW/guide/config-webauthn'},
{text: 'Nginx', link: '/zh_TW/guide/config-nginx'},
{text: 'Node', link: '/zh_TW/guide/config-node'},
{text: 'Open AI', link: '/zh_TW/guide/config-openai'},
{text: 'Terminal', link: '/zh_TW/guide/config-terminal'},
{text: 'Webauthn', link: '/zh_TW/guide/config-webauthn'}
]
},
{
Expand Down
20 changes: 20 additions & 0 deletions docs/guide/config-app.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# App

## PageSize

- Type: `int`
- Default: 10
- Version: `>=v2.0.0-beta.37`

This option is used to set the page size of list pagination in the Nginx UI. Adjusting the page size can help in
managing large amounts of data more effectively, but a too large number can increase the load on the server.

## JwtSecret
- Type: `string`
- Version: `>=v2.0.0-beta.37`

This option is used to configure the key used by the Nginx UI server to generate JWT.

JWT is a standard for verifying user identity. It can generate a token after the user logs in, and then use the token to verify the user's identity in subsequent requests.

If you use the one-click installation script to deploy Nginx UI, the script will generate a UUID value and set it as the value of this option.
43 changes: 43 additions & 0 deletions docs/guide/config-cert.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Cert

## CADir
- Type: `string`
- Version:`>= v2.0.0-beta.37`

When applying for a Let's Encrypt certificate, we use the default CA address of Let's Encrypt. If you need to debug or
obtain certificates from other providers, you can set CADir to their address.

::: tip
Please note that the address provided by
CADir needs to comply with the `RFC 8555` standard.
:::

## RecursiveNameservers

- Version:`>= v2.0.0-beta.37`
- Type: `[]string`
- Example: `8.8.8.8:53,1.1.1.1:53`

This option is used to set the recursive nameservers used by
Nginx UI in the DNS challenge step of applying for a certificate.
If this option is not configured, Nginx UI will use the nameservers settings of the operating system.


## CertRenewalInterval

- Version:`>= v2.0.0-beta.37`
- Type: `int`
- Default value: `7`

This option is used to set the automatic renewal interval of the Let's Encrypt certificate.
By default, Nginx UI will automatically renew the certificate every 7 days.

## HTTPChallengePort

- Version:`>= v2.0.0-beta.37`
- Type: `int`
- Default: `9180`

This option is used to set the port for backend listening in the HTTP01 challenge mode when obtaining Let's Encrypt
certificates. The HTTP01 challenge is a domain validation method used by Let's Encrypt to verify that you control the
domain for which you're requesting a certificate.
8 changes: 8 additions & 0 deletions docs/guide/config-database.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Database

## Name
- Type: `string`
- Default: `database`
- Version: `>=v2.0.0-beta.37`

This option is used to set the name of the sqlite database used by Nginx UI to store its data.
18 changes: 18 additions & 0 deletions docs/guide/config-http.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Http

## GithubProxy

- Type: `string`
- Version: `>= v2.0.0-beta.37`
- Suggestion: `https://mirror.ghproxy.com/`

For users who may experience difficulties downloading resources from GitHub (such as in mainland China), this option
allows them to set a proxy for github.com to improve accessibility.

## InsecureSkipVerify

- Version:`>= v2.0.0-beta.37`
- Type: `bool`

This option is used to skip the verification of the certificate of servers when Nginx UI sends requests to them.

16 changes: 16 additions & 0 deletions docs/guide/config-node.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Node

## Name

- Version:`>= v2.0.0-beta.37`
- Type: `string`

Use this option to customize the name of local server to be displayed in the environment indicator.


## Secret
- Type: `string`
- Version: `>= v2.0.0-beta.37`

This secret is used to authenticate the communication between the Nginx UI servers.
Also, you can use this secret to access the Nginx UI API without a password.
Loading

0 comments on commit 80cb8e1

Please sign in to comment.