Skip to content

Commit

Permalink
更新DDNS信息 (#94)
Browse files Browse the repository at this point in the history
  • Loading branch information
uubulb authored Aug 24, 2024
1 parent 62afb88 commit 1111f53
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 26 deletions.
33 changes: 19 additions & 14 deletions docs/en_US/guide/servers.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,10 @@ The forced update will not work if `disable-force-update` is enabled.

This is WebShell; the feature will not work if `disable-command-execute` is enabled.
It is available for both Linux and Windows and supports Ctrl+Shift+V for pasting.
If the connection fails, refer to [Real-Time Channel Disconnection/Online Terminal Connection Failure](/en_US/guide/q4.html).
Note that in the WebSSH terminal function, the Agent connects to the **public access domain** via WebSocket, not through gRPC.
If the connection fails, refer to [Real-Time Channel Disconnection/Online Terminal Connection Failure](/en_US/guide/q4.html).

## FM
Added in Dashboard v0.19.1 / Agent v0.19.0. A pseudo file manager embedded in WebShell, supports file download/upload, directory navigation and copying current path. Access it by clicking the blue button in the bottom-right corner of the WebShell.

## DDNS Functionality

Expand All @@ -52,9 +54,12 @@ The DDNS functionality is suitable for servers with dynamic IPs. When the Agent

### Configuration Instructions

Currently, the DDNS functionality supports two configuration forms: single configuration and multiple configurations. If single configuration is used, all Agent servers will use the same configuration to update DDNS. If multiple configurations are used, each server can be assigned a specific configuration to update DDNS, offering greater flexibility.
You can choose to use profiles or not; If no profile is set, all Agent servers will use the same configuration to update DDNS. If profiles are used, each server can have a specific configuration for updating DDNS, providing greater flexibility.

#### Single Configuration
#### Without Profiles
::: warning
This configuration is deprecated and will be removed in a future release. Please switch to using profiles instead.
:::

```yaml
DDNS:
Expand All @@ -81,11 +86,11 @@ DDNS:
- `MaxRetries`: The number of retry attempts when a request fails.
- `Profiles`: Multi-configuration settings; ignored in single configuration settings.

The `WebhookURL`, `WebhookRequestBody`, and `WebhookHeaders` can include the following parameters:
The `WebhookURL`, `WebhookRequestBody`, and `WebhookHeaders` can include the following placeholders:

- `{ip}`: The current IP of the server.
- `{domain}`: The DDNS domain.
- `{type}`: The IP type, which could be "ipv4" or "ipv6".
- `{domain}`: The DDNS domain. If used with `WebhookURL`, only query values will be replaced.
- `{type}`: The IP type, either "ipv4" or "ipv6".
- `{access_id}`: Credential 1.
- `{access_secret}`: Credential 2.

Expand All @@ -98,9 +103,9 @@ WebhookHeaders: |
WebhookRequestBody: '{"domain": "{domain}", "ip": "{ip}", "type": "{type}"}'
```

#### Multiple Configurations
#### With Profiles

When using multiple configurations, leave the `DDNS.Provider` value empty. If `DDNS.Provider` is not empty, the multiple configuration settings will be ignored.
When using profiles, leave the `DDNS.Provider` value empty. If `DDNS.Provider` is not empty, this configuration will be ignored.

```yaml
DDNS:
Expand All @@ -117,10 +122,10 @@ DDNS:
WebhookHeaders: ""
```

- `Profiles`: Multi-configuration settings.
- `Profiles`: Profile field.
- `example`: Can be replaced with any string as the DDNS configuration name.

Other options can be referenced from the [Single Configuration](#Single-Configuration) section.
Other options can be referenced from the [Without Profiles](#Without-Profiles) section.

#### Dashboard Configuration

Expand All @@ -135,10 +140,10 @@ DDNS related options:
- `DDNS Configuration`: The DDNS configuration name to use in multiple configurations.

::: warning
When you modify the configuration and save it in the Dashboard settings, it will populate the default configuration options in `config.yaml`, and both single and multiple configurations will exist in the DDNS section.
When you modify the configuration and save it in the Dashboard settings, it will populate the default configuration options in `config.yaml`, and all options in the DDNS field will be set with a default value (see [Without Profiles](#Without-Profiles)).

- To use single configuration, configure `DDNS.Provider` and ignore the `Profiles` options.
- To use multiple configurations, leave `DDNS.Provider` empty. If `DDNS.Provider` is not empty, the multiple configuration settings will be ignored.
- If not using profiles, configure `DDNS.Provider` and ignore the `Profiles` options.
- To use profiles, leave `DDNS.Provider` empty. If `DDNS.Provider` is not empty, the `Profiles` field will be ignored.
:::

#### Viewing Logs
Expand Down
2 changes: 1 addition & 1 deletion docs/en_US/guide/services.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ outline: deep

## How to Use

To add a new monitor, go to the "Services" page in the Admin Panel and click "Add Monitor."
To add a new monitor, go to the "Services" page in the Admin dashboard and click "Add Monitor."

When adding a new service monitor, you need to set the following parameters:

Expand Down
27 changes: 16 additions & 11 deletions docs/guide/servers.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,10 @@ Agent 更新相关的参数是 [自定义 Agent 监控项目](/guide/q7.html)

即 WebShell,`disable-command-execute` 开启时此功能不生效。
Linux 和 Windows 均可用,可使用 Ctrl+Shift+V 粘贴。
连接失败请参考[实时通道断开/在线终端连接失败](/guide/q4.html)
注意在线终端功能中,Agent 也是通过 WebSocket 连接到**公开访问域名**,而非通过 gRPC 交互。
连接失败请参考[实时通道断开/在线终端连接失败](/guide/q4.html)

## FM
Dashboard v0.19.1 / Agent v0.19.0 加入的新功能,是嵌入 WebShell 的一个伪文件管理器,提供文件下载和上传功能,也可以进行目录跳转或者复制路径。点击 WebShell 右下角的蓝色按钮就可以打开。

## DDNS 功能

Expand All @@ -52,9 +54,12 @@ DDNS 功能适用于使用动态 IP 的服务器,当 Agent 上报了一个新

### 配置说明

目前 DDNS 功能支持两种形式的配置:单配置和多配置。如使用单配置,则所有 Agent 服务器都使用相同的配置更新 DDNS;如使用多配置,则可为每台服务器指定一个配置更新 DDNS,灵活性更强。
目前 DDNS 功能支持两种形式的配置:**单配置****多配置**。如使用 **单配置**,则所有 Agent 服务器都使用相同的信息更新 DDNS;如使用 **多配置**,则可为每台服务器指定一个配置更新 DDNS,灵活性更强。

#### 单配置
::: warning
此功能已废弃,并将在之后的版本中删除,请尽快迁移至 **多配置** 方式。
:::

```yaml
DDNS:
Expand All @@ -81,9 +86,9 @@ DDNS:
- `MaxRetries`:当请求失败时,重试请求的次数。
- `Profiles`:多配置设定;在单配置设定中,此项忽略。

`WebhookURL`、`WebhookRequestBody` 以及 `WebhookHeaders` 可以包含以下参数
`WebhookURL`(仅对参数生效)、`WebhookRequestBody` 以及 `WebhookHeaders` 可以包含以下占位符

- `{ip}`:主机当前 IP。
- `{ip}`:主机当前 IP,开启 IPv4 则为 IPv4 地址,开启 IPv6 则为 IPv6 地址
- `{domain}`:ddns 域名。
- `{type}`:IP 类型,可能为 "ipv4" 和 "ipv6"。
- `{access_id}`:凭据 1。
Expand All @@ -100,7 +105,7 @@ WebhookRequestBody: '{"domain": "{domain}", "ip": "{ip}", "type": "{type}"}'

#### 多配置

当使用多配置时,请将 `DDNS.Provider` 留空。如 `DDNS.Provider` 的值不为空,多配置设定将被忽略
当使用 **多配置** 时,请将 `DDNS.Provider` 留空。如 `DDNS.Provider` 的值不为空,**多配置** 设定将被忽略

```yaml
DDNS:
Expand All @@ -117,7 +122,7 @@ DDNS:
WebhookHeaders: ""
```

- `Profiles`多配置设定
- `Profiles`配置字段
- `example`:可替换为 DDNS 配置名,可填任意字符串。

其它选项请参考[单配置](#单配置)段。
Expand All @@ -132,13 +137,13 @@ DDNS 相关选项说明:
- `启用 DDNS IPv4`:更新 DDNS 记录时,启用 IPv4 解析。
- `启用 DDNS IPv6`:更新 DDNS 记录时,启用 IPv6 解析。
- `DDNS 域名`:记录指向的域名。
- `DDNS 配置`在多配置情况下,要使用的 DDNS 配置名。
- `DDNS 配置`在 **多配置** 情况下,要使用的 DDNS 配置名。

::: warning
在 Dashboard 设置中修改配置并保存时,会在 `config.yaml` 中填入默认配置选项,此时 DDNS 段中会同时存在单配置和多配置
在 Dashboard 设置中修改配置并保存时,会在 `config.yaml` 中填入默认配置选项,此时 DDNS 段中会同时存在 **单配置** 和 **多配置** 字段

- 如需使用单配置,请配置 `DDNS.Provider`,并忽略 `Profiles` 选项相关内容。
- 如需使用多配置,请将 `DDNS.Provider` 留空。如 `DDNS.Provider` 的值不为空,多配置设定将被忽略。
- 如使用 **单配置**,请配置 `DDNS.Provider`,并忽略 `Profiles` 选项相关内容。
- 如使用 **多配置**,请将 `DDNS.Provider` 留空。如 `DDNS.Provider` 的值不为空,多配置设定将被忽略。
:::

#### 查看日志
Expand Down

0 comments on commit 1111f53

Please sign in to comment.