Skip to content

Commit d056ce2

Browse files
[feature] support dead link check (apache#2579)
Co-authored-by: tomsun28 <[email protected]>
1 parent c2d92eb commit d056ce2

File tree

11 files changed

+83
-11
lines changed

11 files changed

+83
-11
lines changed

.github/exclude_files.txt

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
./home/versioned_docs/version-v1.5.x/community/how-to-release.md
2+
./home/versioned_docs/version-v1.5.x/start/postgresql-change.md
3+
./home/versioned_docs/version-v1.4.x/start/postgresql-change.md
4+
./home/versioned_docs/version-v1.5.x/introduce.md
5+
./home/versioned_docs/version-v1.4.x/introduce.md
6+
./home/versioned_docs/version-v1.5.x/help/sqlserver.md
7+
./home/versioned_docs/version-v1.4.x/help/sqlserver.md
8+
./home/versioned_docs/version-v1.5.x/help/alert_threshold_expr.md
9+
./home/versioned_docs/version-v1.4.x/help/alert_threshold_expr.md
10+
./home/versioned_docs/version-v1.4.x/others/resource.md
11+
./home/versioned_docs/version-v1.5.x/others/resource.md
12+
./home/docs/community/how-to-release.md
13+
./home/blog/2022-06-01-hertzbeat-v1.0.md
14+
./home/blog/2023-12-11-hertzbeat-v1.4.3.md
15+
./home/blog/2023-11-12-hertzbeat-v1.4.2.md
16+
./home/blog/2024-01-18-hertzbeat-v1.4.4.md
17+
./home/docs/introduce.md
18+
./home/docs/help/sqlserver.md
19+
./home/docs/postgresql-change.md
20+
./home/docs/help/alert_threshold_expr.md
21+
./home/docs/others/resource.md
22+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/current/introduce.md
23+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/current/help/sqlserver.md
24+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/current/postgresql-change.md
25+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/current/help/alert_threshold_expr.md
26+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/current/others/resource.md
27+
./home/i18n/zh-cn/docusaurus-plugin-content-blog/2023-11-12-hertzbeat-v1.4.2.md
28+
./home/i18n/zh-cn/docusaurus-plugin-content-blog/2022-06-01-hertzbeat-v1.0.md
29+
./home/i18n/zh-cn/docusaurus-plugin-content-blog/2023-12-11-hertzbeat-v1.4.3.md
30+
./home/i18n/zh-cn/docusaurus-plugin-content-blog/2024-01-18-hertzbeat-v1.4.4.md
31+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.5.x/community/how-to-release.md
32+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.5.x/start/postgresql-change.md
33+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.4.x/start/postgresql-change.md
34+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.5.x/introduce.md
35+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.4.x/introduce.md
36+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.5.x/help/sqlserver.md
37+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.4.x/help/sqlserver.md
38+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.5.x/help/alert_threshold_expr.md
39+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.4.x/help/alert_threshold_expr.md
40+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.4.x/others/resource.md
41+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.5.x/others/resource.md
42+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.5.x/start/tdengine-init.md
43+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.4.x/start/tdengine-init.md
44+
./home/i18n/zh-cn/docusaurus-plugin-content-docs/current/start/tdengine-init.md

.github/link_check.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"ignorePatterns": [
3+
{
4+
"pattern": "^(?!http).*"
5+
},
6+
{
7+
"pattern": "!\\[.*\\]\\((?!http).*\\)"
8+
}
9+
],
10+
"timeout": "10s",
11+
"retryOn429": true,
12+
"retryCount": 10,
13+
"fallbackRetryDelay": "1000s",
14+
"aliveStatusCodes": [
15+
0,
16+
200,
17+
401,
18+
403
19+
]
20+
}

.github/workflows/doc-build-test.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,14 @@ jobs:
114114
else
115115
echo "All file names are valid."
116116
fi
117+
- name: Dead Link
118+
run: |
119+
sudo npm install -g [email protected]
120+
for file in $(find ./home -name "*.md"); do
121+
if ! grep -Fxq "$file" .github/exclude_files.txt; then
122+
markdown-link-check -c .github/link_check.json -q "$file"
123+
fi
124+
done
117125
- name: NPM INSTALL
118126
working-directory: home
119127
run: npm install

home/docs/start/upgrade.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,23 +24,23 @@ Apache HertzBeat (incubating)'s metadata information is stored in H2 or Mysql, P
2424
2. If using the built-in default H2 database
2525
- Need to mount or back up `-v $(pwd)/data:/opt/hertzbeat/data` database file directory in the container `/opt/hertzbeat/data`
2626
- Stop and delete the container, delete the local HertzBeat docker image, and pull the new version image
27-
- Refer to [Docker installation of HertzBeat](docker-deploy) to create a new container using a new image. Note that the database file directory needs to be mounted `-v $(pwd)/data:/opt/hertzbeat/data`
27+
- Refer to [Docker installation of HertzBeat](./docker-deploy) to create a new container using a new image. Note that the database file directory needs to be mounted `-v $(pwd)/data:/opt/hertzbeat/data`
2828
3. If using external relational database Mysql, PostgreSQL
2929
- No need to mount the database file directory in the backup container
3030
- Stop and delete the container, delete the local HertzBeat docker image, and pull the new version image
31-
- Refer to [Docker installation HertzBeat](docker-deploy) to create a new container using the new image, and configure the database connection in `application.yml`
31+
- Refer to [Docker installation HertzBeat](./docker-deploy) to create a new container using the new image, and configure the database connection in `application.yml`
3232

3333
### Upgrade For Package Deploy
3434

3535
1. If using the built-in default H2 database
3636
- Back up the database file directory under the installation package `/opt/hertzbeat/data`
3737
- If there is a custom monitoring template, you need to back up the template YML under `/opt/hertzbeat/define`
3838
- `bin/shutdown.sh` stops the HertzBeat process and downloads the new installation package
39-
- Refer to [Installation package to install HertzBeat](package-deploy) to start using the new installation package
39+
- Refer to [Installation package to install HertzBeat](./package-deploy) to start using the new installation package
4040
2. If using external relational database Mysql, PostgreSQL
4141
- No need to back up the database file directory under the installation package
4242
- If there is a custom monitoring template, you need to back up the template YML under `/opt/hertzbeat/define`
4343
- `bin/shutdown.sh` stops the HertzBeat process and downloads the new installation package
44-
- Refer to [Installation package to install HertzBeat](package-deploy) to start with the new installation package and configure the database connection in `application.yml`
44+
- Refer to [Installation package to install HertzBeat](./package-deploy) to start with the new installation package and configure the database connection in `application.yml`
4545

4646
**HAVE FUN**

script/docker-compose/hertzbeat-mysql-iotdb/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
##### docker compose deploys hertzbeat and its dependent services
1616
1717
1. Download the hertzbeat-docker-compose installation deployment script file
18-
The script file is located in `script/docker-compose/hertzbeat-mysql-iotdb` link [script/docker-compose](https://github.com/hertzbeat/hertzbeat/tree/master/script/docker-compose/ hertzbeat-mysql-iotdb)
18+
The script file is located in `script/docker-compose/hertzbeat-mysql-iotdb` link [script/docker-compose](https://github.com/apache/hertzbeat/tree/master/script/docker-compose/ hertzbeat-mysql-iotdb)
1919
2020
2. Add MYSQL jdbc driver jar
2121

script/docker-compose/hertzbeat-mysql-iotdb/README_CN.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
##### docker compose部署hertzbeat及其依赖服务
1818

1919
1. 下载hertzbeat-docker-compose安装部署脚本文件
20-
脚本文件位于代码仓库下`script/docker-compose/hertzbeat-mysql-iotdb` 链接 [script/docker-compose](https://github.com/hertzbeat/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-iotdb)
20+
脚本文件位于代码仓库下`script/docker-compose/hertzbeat-mysql-iotdb` 链接 [script/docker-compose](https://github.com/apache/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-iotdb)
2121

2222
2. 添加 MYSQL jdbc 驱动 jar
2323
下载 MYSQL jdbc driver jar, 例如 mysql-connector-java-8.0.25.jar. https://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-8.0.25.zip

script/docker-compose/hertzbeat-mysql-tdengine/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
##### docker compose deploys hertzbeat and its dependent services
1616
1717
1. Download the hertzbeat-docker-compose installation deployment script file
18-
The script file is located in `script/docker-compose/hertzbeat-mysql-tdengine` link [script/docker-compose](https://github.com/hertzbeat/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-tdengine)
18+
The script file is located in `script/docker-compose/hertzbeat-mysql-tdengine` link [script/docker-compose](https://github.com/apache/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-tdengine)
1919
2020
2. Add MYSQL jdbc driver jar
2121

script/docker-compose/hertzbeat-mysql-tdengine/README_CN.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
##### docker compose部署hertzbeat及其依赖服务
1818

1919
1. 下载hertzbeat-docker-compose安装部署脚本文件
20-
脚本文件位于代码仓库下`script/docker-compose/hertzbeat-mysql-tdengine` 链接 [script/docker-compose](https://github.com/hertzbeat/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-tdengine)
20+
脚本文件位于代码仓库下`script/docker-compose/hertzbeat-mysql-tdengine` 链接 [script/docker-compose](https://github.com/apache/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-tdengine)
2121

2222
2. 添加 MYSQL jdbc 驱动 jar
2323
下载 MYSQL jdbc driver jar, 例如 mysql-connector-java-8.0.25.jar. https://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-8.0.25.zip

script/docker-compose/hertzbeat-mysql-victoria-metrics/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
##### docker compose deploys hertzbeat and its dependent services
1616
1717
1. Download the hertzbeat-docker-compose installation deployment script file
18-
The script file is located in `script/docker-compose/hertzbeat-mysql-victoria-metrics` link [script/docker-compose](https://github.com/hertzbeat/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-victoria-metrics)
18+
The script file is located in `script/docker-compose/hertzbeat-mysql-victoria-metrics` link [script/docker-compose](https://github.com/apache/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-victoria-metrics)
1919
2020
2. Add MYSQL jdbc driver jar
2121

script/docker-compose/hertzbeat-mysql-victoria-metrics/README_CN.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
##### docker compose部署hertzbeat及其依赖服务
1818

1919
1. 下载hertzbeat-docker-compose安装部署脚本文件
20-
脚本文件位于代码仓库下`script/docker-compose/hertzbeat-mysql-victoria-metrics` 链接 [script/docker-compose](https://github.com/hertzbeat/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-mysql-victoria-metrics)
20+
脚本文件位于代码仓库下`script/docker-compose/hertzbeat-mysql-victoria-metrics` 链接 [script/docker-compose](https://github.com/apache/hertzbeat/tree/master/script/docker-compose/hertzbeat-mysql-victoria-metrics)
2121

2222
2. 添加 MYSQL jdbc 驱动 jar
2323
下载 MYSQL jdbc driver jar, 例如 mysql-connector-java-8.0.25.jar. https://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-8.0.25.zip

script/docker-compose/hertzbeat-postgresql-victoria-metrics/README_CN.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
##### docker compose部署hertzbeat及其依赖服务
1818

1919
1. 下载hertzbeat-docker-compose安装部署脚本文件
20-
脚本文件位于代码仓库下`script/docker-compose/hertzbeat-postgre-victoria-metrics` 链接 [script/docker-compose](https://github.com/apache/hertzbeat/tree/master/script/docker-compose/hertzbeat-postgre-victoria-metrics)
20+
脚本文件位于代码仓库下`script/docker-compose/hertzbeat-postgre-victoria-metrics` 链接 [script/docker-compose](https://github.com/apache/hertzbeat/tree/master/script/docker-compose/hertzbeat-postgresql-victoria-metrics)
2121

2222

2323
2. 进入部署脚本 docker-compose 目录, 执行

0 commit comments

Comments
 (0)