Skip to content

Commit 12534c8

Browse files
Merge pull request #304 from Websoft9/dev
Dev
2 parents fd4c7d2 + a54aa9c commit 12534c8

6 files changed

Lines changed: 44 additions & 100 deletions

File tree

i18n/en/docusaurus-plugin-content-docs/version-2.0/apps/opencost.md

Lines changed: 4 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@
22
title: OpenCost
33
slug: /opencost
44
tags:
5-
- console
6-
- other
5+
- Cloud Optimization
6+
- Cost Management
7+
- OpenCost
78
---
89

910
import Meta from './_include/opencost.md';
@@ -12,12 +13,6 @@ import Meta from './_include/opencost.md';
1213

1314
## Getting started{#guide}
1415

15-
### Initial setup{#wizard}
16-
17-
1. When completed installation of OpenCost at **Websoft9 Console**, get the applicaiton's **Overview** and **Access** information from **My Apps**
18-
19-
2. Complete the install wizard step by step
20-
2116
### Login verification{#verification}
2217

2318
1. Completed installation OpenCost at Websoft9 console, get the applicaiton's overview and access credentials from **My Apps**
@@ -26,18 +21,6 @@ import Meta from './_include/opencost.md';
2621

2722
## Configuration options{#configs}
2823

29-
- CLI
30-
- Multilingual (√)
31-
- SMTP (√)
32-
3324
## Administer{#administrator}
3425

35-
- **Password recover**
36-
- **Change URL**
37-
- **HTTPS**
38-
- **Online backup**
39-
- **Online upgrade**
40-
41-
## Troubleshooting{#troubleshooting}
42-
43-
#### 502 failed code?
26+
## Troubleshooting{#troubleshooting}

i18n/en/docusaurus-plugin-content-docs/version-2.0/apps/zerotier.md

Lines changed: 8 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@
22
title: ZeroTier
33
slug: /zerotier
44
tags:
5-
- console
6-
- other
5+
- VPN
6+
- Certification network
7+
- ZeroTier
78
---
89

910
import Meta from './_include/zerotier.md';
@@ -14,30 +15,16 @@ import Meta from './_include/zerotier.md';
1415

1516
### Initial setup{#wizard}
1617

17-
1. When completed installation of ZeroTier at **Websoft9 Console**, get the applicaiton's **Overview** and **Access** information from **My Apps**
18+
1. Register account at [my.zerotier.com](https://my.zerotier.com/) and create a vitual network and get the **Network ID**
1819

19-
2. Complete the install wizard step by step
20+
2. Install Zerotier from at Websoft9 AppStore where need to input **Network ID** before installation
2021

21-
### Login verification{#verification}
22+
3. Logint to [my.zerotier.com](https://my.zerotier.com/) and [Authorize your device on your network](https://docs.zerotier.com/start/#authorize-your-device-on-your-network)
2223

23-
1. Completed installation ZeroTier at Websoft9 console, get the applicaiton's overview and access credentials from **My Apps**
24-
25-
2. Starting to verify it
24+
4. Get **Managed IPs** of your device from **my.zerotier.com** console, and connect each other by this IPs
2625

2726
## Configuration options{#configs}
2827

29-
- CLI
30-
- Multilingual (√)
31-
- SMTP (√)
32-
3328
## Administer{#administrator}
3429

35-
- **Password recover**
36-
- **Change URL**
37-
- **HTTPS**
38-
- **Online backup**
39-
- **Online upgrade**
40-
41-
## Troubleshooting{#troubleshooting}
42-
43-
#### 502 failed code?
30+
## Troubleshooting{#troubleshooting}

src/theme/Layout.js

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,27 +3,32 @@ import { useLocation } from '@docusaurus/router';
33
import OriginalLayout from '@theme-original/Layout';
44
import React, { useEffect } from 'react';
55
import { useHistory } from 'react-router-dom';
6+
import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
67

78
function useRemoveTrailingSlash() {
9+
const { i18n } = useDocusaurusContext();
810
const location = useLocation();
911
const history = useHistory();
1012

1113
useEffect(() => {
1214
const { pathname, search, hash } = location;
15+
16+
// 跳过多语言根路径(如 /en/、/zh-cn/)
17+
const isI18nRootPath = new RegExp(`^/(${i18n.locales.join('|')})/$`).test(pathname);
18+
if (isI18nRootPath) {
19+
return; // 保留多语言根路径的尾部斜杠
20+
}
21+
22+
// 仅处理非多语言根路径的尾部斜杠
1323
if (pathname.length > 1 && pathname.endsWith('/')) {
1424
const newPath = pathname.slice(0, -1) + search + hash;
15-
console.log(`old pathname: ${pathname}, Redirecting to: ${newPath}`);
16-
// 使用 history.replace 以避免页面刷新
25+
console.log(`Redirecting from ${pathname} to ${newPath}`);
1726
history.replace(newPath);
1827
}
19-
}, [location, history]);
28+
}, [location, history, i18n.locales]);
2029
}
2130

2231
export default function Layout(props) {
2332
useRemoveTrailingSlash();
24-
2533
return <OriginalLayout {...props} />;
26-
}
27-
28-
//window.history.replaceState(null, '', newPath);
29-
//window.location.replace(newPath);
34+
}

versioned_docs/version-2.0/apps/opencost.md

Lines changed: 4 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
title: OpenCost
33
slug: /opencost
44
tags:
5-
- Web 面板
6-
- 可视化
7-
- GUI
5+
- 云成本管理
6+
- 云计算
7+
- OpenCost
88
---
99

1010
import Meta from './_include/opencost.md';
@@ -13,31 +13,12 @@ import Meta from './_include/opencost.md';
1313

1414
## 入门指南{#guide}
1515

16-
### 初始化{#wizard}
17-
18-
Websoft9 控制台安装 OpenCost 后,通过 **我的应用** 查看应用详情,在 **访问** 标签页中获取登录信息。
19-
2016
### 登录后台{#console}
2117

2218
Websoft9 控制台安装 OpenCost 后,通过 **我的应用** 查看应用详情,在 **访问** 标签页中获取登录信息。
2319

24-
### 安装插件{#plugin}
25-
2620
## 配置选项{#configs}
2721

28-
- CLI
29-
- 多语言(√)
30-
- SMTP(√)
31-
- 插件市场(√)
32-
3322
## 管理维护{#administrator}
3423

35-
- **重置管理员密码**
36-
- **更换 URL**
37-
- **HTTPS 额外设置**
38-
- **在线备份**
39-
- **在线升级**
40-
41-
## 故障
42-
43-
#### 更改域名导致无法访问 ?
24+
## 故障

versioned_docs/version-2.0/apps/tensorflow.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,20 +12,20 @@ import Meta from './_include/tensorflow.md';
1212

1313
## 入门指南{#guide}
1414

15-
### 登录 Jupter{#wizard}
15+
### 登录 Jupyter{#wizard}
1616

1717
Websoft9 控制台安装 TensorFlow 后,通过 "我的应用" 查看应用详情,在 "访问" 标签页中获取访问信息。
1818

19-
1. 本地浏览器访问 URL,进入 Jupter 登陆页面,提示需要 Token
19+
1. 本地浏览器访问 URL,进入 Jupyter 登陆页面,提示需要 Token
2020

2121
2. 进入 TensorFlow 容器的命令模式,运行 `jupyter notebook list`,获取 Token
2222

23-
3. 使用 Token 登录或设置一个密码后,登录到 Jupter 后台
23+
3. 使用 Token 登录或设置一个密码后,登录到 Jupyter 后台
2424
![](./assets/tensorflow-jupter-websoft9.png)
2525

2626
### 运行 TensorBoard
2727

28-
1. Jupter 后台依次打开:**New > Python 3 (ipykernel)**
28+
1. Jupyter 后台依次打开:**New > Python 3 (ipykernel)**
2929

3030
2. 参考 [Using TensorBoard in Notebooks](https://tensorflow.google.cn/tensorboard/tensorboard_in_notebooks),逐一运行范例程序。最后的命令增加一个参数`--host 0.0.0.0` (允许外网访问)
3131

@@ -37,7 +37,7 @@ Websoft9 控制台安装 TensorFlow 后,通过 "我的应用" 查看应用详
3737

3838
- 容器端口
3939

40-
- 8888:Jupter 端口
40+
- 8888:Jupyter 端口
4141
- 6006:TensorBoard 端口
4242

4343
## 管理维护{#administrator}

versioned_docs/version-2.0/apps/zerotier.md

Lines changed: 10 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
title: ZeroTier
33
slug: /zerotier
44
tags:
5-
- Web 面板
6-
- 可视化
7-
- GUI
5+
- VPN
6+
- 认证网络
7+
- ZeroTier
88
---
99

1010
import Meta from './_include/zerotier.md';
@@ -13,31 +13,19 @@ import Meta from './_include/zerotier.md';
1313

1414
## 入门指南{#guide}
1515

16-
### 初始化{#wizard}
16+
### 快速开始
1717

18-
Websoft9 控制台安装 ZeroTier 后,通过 **我的应用** 查看应用详情,在 **访问** 标签页中获取登录信息。
18+
1.[my.zerotier.com](https://my.zerotier.com/) 注册账户,创建一个虚拟网络并获取**网络 ID**
1919

20-
### 登录后台{#console}
20+
2. 从 Websoft9 AppStore 安装 Zerotier,安装前需要输入**网络 ID**
2121

22-
Websoft9 控制台安装 ZeroTier 后,通过 **我的应用** 查看应用详情,在 **访问** 标签页中获取登录信息。
22+
3. 登录 [my.zerotier.com](https://my.zerotier.com/)[在网络上授权您的设备](https://docs.zerotier.com/start/#authorize-your-device-on-your-network)
2323

24-
### 安装插件{#plugin}
24+
4.**my.zerotier.com**控制台获取设备的**受管 IP**,并通过此 IP 互相连接
2525

26-
## 配置选项{#configs}
2726

28-
- CLI
29-
- 多语言(√)
30-
- SMTP(√)
31-
- 插件市场(√)
27+
## 配置选项{#configs}
3228

3329
## 管理维护{#administrator}
3430

35-
- **重置管理员密码**
36-
- **更换 URL**
37-
- **HTTPS 额外设置**
38-
- **在线备份**
39-
- **在线升级**
40-
41-
## 故障
42-
43-
#### 更改域名导致无法访问 ?
31+
## 故障

0 commit comments

Comments
 (0)