mirror of
https://github.com/certd/certd.git
synced 2026-04-14 20:40:53 +08:00
Compare commits
104 Commits
v2-dev-aut
...
v1.36.14
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f3a90a63b6 | ||
|
|
2494173aec | ||
|
|
866eb6241b | ||
|
|
86b3df1941 | ||
|
|
e87f6d56f5 | ||
|
|
acc890730f | ||
|
|
b0707739fd | ||
|
|
251dd1fe45 | ||
|
|
b9f3dc65e0 | ||
|
|
238ad7ce51 | ||
|
|
99fd5fca4d | ||
|
|
8eda77b76d | ||
|
|
81ac240ac8 | ||
|
|
6109798fab | ||
|
|
95715a007d | ||
|
|
b33ec201ac | ||
|
|
b53fbaf5b3 | ||
|
|
1e03a2e553 | ||
|
|
fda7c6f67a | ||
|
|
fabb7982ff | ||
|
|
cbf206be60 | ||
|
|
aa0c282205 | ||
|
|
9759365329 | ||
|
|
e3738f6422 | ||
|
|
9746d169f9 | ||
|
|
2e6d03ff00 | ||
|
|
f7b7d3d65e | ||
|
|
4037cf11aa | ||
|
|
02aeb321ce | ||
|
|
0012619257 | ||
|
|
6f3ade0d94 | ||
|
|
cf572f328a | ||
|
|
d1ce36038c | ||
|
|
b382351c7b | ||
|
|
4e5e862f58 | ||
|
|
ab84835362 | ||
|
|
41ce8489dc | ||
|
|
ef3faf5832 | ||
|
|
edf089ec9e | ||
|
|
0ae9a3605c | ||
|
|
7f9c4e52ac | ||
|
|
35947f96a8 | ||
|
|
b0f91f1eea | ||
|
|
13dfca1749 | ||
|
|
9d9cd8a362 | ||
|
|
5e5c41fda5 | ||
|
|
3ebdc52b3e | ||
|
|
af54f48cec | ||
|
|
8656059151 | ||
|
|
a6d38f2458 | ||
|
|
085bdf5cfa | ||
|
|
6883bcacee | ||
|
|
2ecc6e0368 | ||
|
|
8fb5ca2fe1 | ||
|
|
e40345095f | ||
|
|
ffc0c7bb7b | ||
|
|
58fadc8928 | ||
|
|
d96a607c04 | ||
|
|
2ea2c8c05f | ||
|
|
b15f514018 | ||
|
|
05a33a0ec9 | ||
|
|
747d266742 | ||
|
|
522d30545b | ||
|
|
6135a44a8d | ||
|
|
7c7d646792 | ||
|
|
4a36fd2ec3 | ||
|
|
b1bcc287cb | ||
|
|
6f5868a9d7 | ||
|
|
75863441f4 | ||
|
|
9763cb00e5 | ||
|
|
521599ef39 | ||
|
|
1921a64f4b | ||
|
|
6b73f5d555 | ||
|
|
e0408f30ba | ||
|
|
dca44fa093 | ||
|
|
bbacb76581 | ||
|
|
1da8617a53 | ||
|
|
e5967f7e9d | ||
|
|
65d84f9e9d | ||
|
|
93e9498b41 | ||
|
|
95332d5db9 | ||
|
|
9864792bbf | ||
|
|
ca9d1eed7a | ||
|
|
38e867c917 | ||
|
|
1ff6daaa27 | ||
|
|
3ee1dbb8a5 | ||
|
|
b4571d5c98 | ||
|
|
29d49d72f9 | ||
|
|
81de0fc7e4 | ||
|
|
9d5d266d2a | ||
|
|
b97935299f | ||
|
|
32a7ea1c16 | ||
|
|
9fd95e6a1e | ||
|
|
61ba83c775 | ||
|
|
6369fed5fc | ||
|
|
42f4d1477d | ||
|
|
609ac9c9a2 | ||
|
|
79f2367472 | ||
|
|
dfc9362084 | ||
|
|
487b469603 | ||
|
|
19e1df1e5d | ||
|
|
fc55010888 | ||
|
|
902d246d1a | ||
|
|
dbf69bcd98 |
94
CHANGELOG.md
94
CHANGELOG.md
@@ -3,6 +3,100 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复复制流水线为空的bug ([b070773](https://github.com/certd/certd/commit/b0707739fdfbae3d78db4efd3f180db05c4e4164))
|
||||||
|
* 修复商用证书上传第二次运行无法使用pfx格式证书的bug ([251dd1f](https://github.com/certd/certd/commit/251dd1fe457a7b152f43eb6de18f7beb9f0b194e))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 1panel支持 currenNode ([acc8907](https://github.com/certd/certd/commit/acc890730f43d492c9b1bd3668814cf10efdf7b8))
|
||||||
|
* 授权管理支持模糊查询 ([866eb62](https://github.com/certd/certd/commit/866eb6241baa7b21f6eddc649966324c188236c6))
|
||||||
|
* 新增找回密码功能 [@nicheng-he](https://github.com/nicheng-he) ([81ac240](https://github.com/certd/certd/commit/81ac240ac84db0af2f56b6352e227ecb49f38377))
|
||||||
|
* 优化start脚本 ([238ad7c](https://github.com/certd/certd/commit/238ad7ce51f17e1098c624e7f61ee2d98de1e02d))
|
||||||
|
* 运行主机脚本插件支持选择运行策略 ([86b3df1](https://github.com/certd/certd/commit/86b3df194126476e1f58e0952a77e986f62eecce))
|
||||||
|
* cdnfly 支持 账号密码登陆授权 ([e87f6d5](https://github.com/certd/certd/commit/e87f6d56f524dbbb9e3243e382b348b6e49f0d2c))
|
||||||
|
* k8s ack、tke 支持重启ingress ([95715a0](https://github.com/certd/certd/commit/95715a007d931c64fa7dd953d94957398e00a443))
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复阿里云发送短信验证码失败的bug ([2e6d03f](https://github.com/certd/certd/commit/2e6d03ff001f521f57368e7a62b97ed7b122e8d0))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 阿里云部分插件优化 [@nicheng-he](https://github.com/nicheng-he) ([e3738f6](https://github.com/certd/certd/commit/e3738f6422270d75ec414c15a343248cc4cad6e1))
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 上传到阿里云cas,证书前缀无效的bug ([b382351](https://github.com/certd/certd/commit/b382351c7b91ec10e1f61d94bec5aad075207ec8))
|
||||||
|
* 修复自定义插件onlyAdmin报错的bug ([4e5e862](https://github.com/certd/certd/commit/4e5e862f5834ad180e4428959c272d444a6f78ab))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署到k8s,tke,ack忽悠证书校验 ([ab84835](https://github.com/certd/certd/commit/ab848353621869464a2c9a45fdb5e28d998b8a58))
|
||||||
|
* 首页增加更新日志按钮 ([41ce848](https://github.com/certd/certd/commit/41ce8489dc2f03a705dfa3fbb357769defb56c60))
|
||||||
|
* 增加版本过低提示 ([d1ce360](https://github.com/certd/certd/commit/d1ce36038cab72b5dc1b320d0a708c261ffbdacb))
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 安全更新,备份数据库插件仅限管理员运行 ([13dfca1](https://github.com/certd/certd/commit/13dfca1749275526c82465a17c482b607c820fdd))
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 企业微信通知改成text类型,因为markdown类型不支持@用户 ([747d266](https://github.com/certd/certd/commit/747d26674248082e678a3fd5ecc94712641a2716))
|
||||||
|
* api接口获取不到证书的bug ([05a33a0](https://github.com/certd/certd/commit/05a33a0ec9999e2802f6c7b23cc1c61a2b9e963d))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署到阿里云oss插件支持选择上传到阿里云cas中的证书 ([2ea2c8c](https://github.com/certd/certd/commit/2ea2c8c05fc40f79595f1bbde67c1413558bf684))
|
||||||
|
* 优化子域名托管的说明 ([b15f514](https://github.com/certd/certd/commit/b15f514018b728acb0922ee3f93c1f302eb5d471))
|
||||||
|
* 账号即将过期通知 ([e403450](https://github.com/certd/certd/commit/e40345095f31e2fb8e2333a6647466659133fa0c))
|
||||||
|
* 子域名托管重复域名不允许添加 ([ffc0c7b](https://github.com/certd/certd/commit/ffc0c7bb7b16d9904fd2d905d1c4e1d4854e92a9))
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复ssh无法执行命令的bug ([9763cb0](https://github.com/certd/certd/commit/9763cb00e5d95b2fa5d1c2d3d4a8eecac71600e6))
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复流水线列表页报length错误的bug ([9864792](https://github.com/certd/certd/commit/9864792bbfd149e770d6e1ffa809573694f99dd3))
|
||||||
|
* 修复流水线页面状态没有刷新的bug ([93e9498](https://github.com/certd/certd/commit/93e9498b410353f504e11e264db62468895d7290))
|
||||||
|
* 修复自定义证书检查时间重启之后不生效的bug ([38e867c](https://github.com/certd/certd/commit/38e867c917bbc68bd228bdd8064f3e7358d6413d))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 支持上传证书到各种对象存储,oss、cos、七牛、s3、minio等 ([1da8617](https://github.com/certd/certd/commit/1da8617a53a675776635bbc3bcb3c6d7dff83e27))
|
||||||
|
* 支持邮箱发送证书 ([95332d5](https://github.com/certd/certd/commit/95332d5db96cd54ddab6ab737332417a09169b39))
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复某些页面翻译不全显示错误的bug ([0b3158f](https://github.com/certd/certd/commit/0b3158fdd5fe5bb0a98c4e65715dbc3de2c38047))
|
||||||
|
* 修复运行流水线后会闪烁一下的bug ([dfc9362](https://github.com/certd/certd/commit/dfc9362084082ee535b898f23b2609c1d946a6fd))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署plesk证书,支持删除未使用的证书 ([902d246](https://github.com/certd/certd/commit/902d246d1a7473ad90f604028c4eb09c8c67d99c))
|
||||||
|
* 通知和定时器的删除按钮显示为红色更显眼 ([61ba83c](https://github.com/certd/certd/commit/61ba83c77546c3d505d081e19a3d68c127662bf1))
|
||||||
|
* 优化流水线列表页面、详情页面性能,精简返回数据 ([609ac9c](https://github.com/certd/certd/commit/609ac9c9a2dde605eb09834ae59693c1cb238765))
|
||||||
|
* 支持自动选择校验方式申请证书 ([3f99432](https://github.com/certd/certd/commit/3f9943270cfb12946e38e6272bc5e8d95ad6ab9e))
|
||||||
|
* OpenAPI支持autoApply参数 ([42f4d14](https://github.com/certd/certd/commit/42f4d1477dc791520a874aed56035abcbc8c433b))
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
|||||||
@@ -16,7 +16,6 @@ Certd® 是一个免费的全自动证书管理系统,让你的网站证书永
|
|||||||
|
|
||||||
> 流水线数量现已调整为无限制,欢迎大家使用
|
> 流水线数量现已调整为无限制,欢迎大家使用
|
||||||
|
|
||||||
|
|
||||||
## 一、特性
|
## 一、特性
|
||||||
本项目不仅支持证书申请过程自动化,还可以自动化部署更新证书,让你的证书永不过期。
|
本项目不仅支持证书申请过程自动化,还可以自动化部署更新证书,让你的证书永不过期。
|
||||||
|
|
||||||
@@ -87,8 +86,8 @@ https://certd.handfree.work/
|
|||||||
1. 【推荐】[Docker方式部署 ](https://certd.docmirror.cn/guide/install/docker/)
|
1. 【推荐】[Docker方式部署 ](https://certd.docmirror.cn/guide/install/docker/)
|
||||||
2. 【推荐】[宝塔面板方式部署 ](https://certd.docmirror.cn/guide/install/docker/)
|
2. 【推荐】[宝塔面板方式部署 ](https://certd.docmirror.cn/guide/install/docker/)
|
||||||
3. 【推荐】[1Panel面板方式部署](https://certd.docmirror.cn/guide/install/1panel/)
|
3. 【推荐】[1Panel面板方式部署](https://certd.docmirror.cn/guide/install/1panel/)
|
||||||
4. 【推荐】[雨云一键部署](https://app.rainyun.com/apps/rca/store/6646/?ref=NzExMDQ2_) : 首充翻倍,每月仅需2.2元
|
4. 【推荐】[雨云一键部署](https://app.rainyun.com/apps/rca/store/6646/?ref=NzExMDQ2) : 首充翻倍,每月仅需2.2元
|
||||||
[<img src="https://rainyun-apps.cn-nb1.rains3.com/materials/deploy-on-rainyun-cn.svg">](https://app.rainyun.com/apps/rca/store/6646/?ref=NzExMDQ2_)
|
[<img src="https://rainyun-apps.cn-nb1.rains3.com/materials/deploy-on-rainyun-cn.svg">](https://app.rainyun.com/apps/rca/store/6646/?ref=NzExMDQ2)
|
||||||
5. 【不推荐】[源码方式部署 ](https://certd.docmirror.cn/guide/install/source/)
|
5. 【不推荐】[源码方式部署 ](https://certd.docmirror.cn/guide/install/source/)
|
||||||
|
|
||||||
#### Docker镜像说明:
|
#### Docker镜像说明:
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
10:51
|
23:41
|
||||||
|
|||||||
@@ -3,6 +3,83 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复阿里云发送短信验证码失败的bug ([2e6d03f](https://github.com/certd/certd/commit/2e6d03ff001f521f57368e7a62b97ed7b122e8d0))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 阿里云部分插件优化 [@nicheng-he](https://github.com/nicheng-he) ([e3738f6](https://github.com/certd/certd/commit/e3738f6422270d75ec414c15a343248cc4cad6e1))
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 上传到阿里云cas,证书前缀无效的bug ([b382351](https://github.com/certd/certd/commit/b382351c7b91ec10e1f61d94bec5aad075207ec8))
|
||||||
|
* 修复自定义插件onlyAdmin报错的bug ([4e5e862](https://github.com/certd/certd/commit/4e5e862f5834ad180e4428959c272d444a6f78ab))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署到k8s,tke,ack忽悠证书校验 ([ab84835](https://github.com/certd/certd/commit/ab848353621869464a2c9a45fdb5e28d998b8a58))
|
||||||
|
* 首页增加更新日志按钮 ([41ce848](https://github.com/certd/certd/commit/41ce8489dc2f03a705dfa3fbb357769defb56c60))
|
||||||
|
* 增加版本过低提示 ([d1ce360](https://github.com/certd/certd/commit/d1ce36038cab72b5dc1b320d0a708c261ffbdacb))
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 安全更新,备份数据库插件仅限管理员运行 ([13dfca1](https://github.com/certd/certd/commit/13dfca1749275526c82465a17c482b607c820fdd))
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 企业微信通知改成text类型,因为markdown类型不支持@用户 ([747d266](https://github.com/certd/certd/commit/747d26674248082e678a3fd5ecc94712641a2716))
|
||||||
|
* api接口获取不到证书的bug ([05a33a0](https://github.com/certd/certd/commit/05a33a0ec9999e2802f6c7b23cc1c61a2b9e963d))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署到阿里云oss插件支持选择上传到阿里云cas中的证书 ([2ea2c8c](https://github.com/certd/certd/commit/2ea2c8c05fc40f79595f1bbde67c1413558bf684))
|
||||||
|
* 优化子域名托管的说明 ([b15f514](https://github.com/certd/certd/commit/b15f514018b728acb0922ee3f93c1f302eb5d471))
|
||||||
|
* 账号即将过期通知 ([e403450](https://github.com/certd/certd/commit/e40345095f31e2fb8e2333a6647466659133fa0c))
|
||||||
|
* 子域名托管重复域名不允许添加 ([ffc0c7b](https://github.com/certd/certd/commit/ffc0c7bb7b16d9904fd2d905d1c4e1d4854e92a9))
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复ssh无法执行命令的bug ([9763cb0](https://github.com/certd/certd/commit/9763cb00e5d95b2fa5d1c2d3d4a8eecac71600e6))
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复流水线列表页报length错误的bug ([9864792](https://github.com/certd/certd/commit/9864792bbfd149e770d6e1ffa809573694f99dd3))
|
||||||
|
* 修复流水线页面状态没有刷新的bug ([93e9498](https://github.com/certd/certd/commit/93e9498b410353f504e11e264db62468895d7290))
|
||||||
|
* 修复自定义证书检查时间重启之后不生效的bug ([38e867c](https://github.com/certd/certd/commit/38e867c917bbc68bd228bdd8064f3e7358d6413d))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 支持上传证书到各种对象存储,oss、cos、七牛、s3、minio等 ([1da8617](https://github.com/certd/certd/commit/1da8617a53a675776635bbc3bcb3c6d7dff83e27))
|
||||||
|
* 支持邮箱发送证书 ([95332d5](https://github.com/certd/certd/commit/95332d5db96cd54ddab6ab737332417a09169b39))
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复某些页面翻译不全显示错误的bug ([0b3158f](https://github.com/certd/certd/commit/0b3158fdd5fe5bb0a98c4e65715dbc3de2c38047))
|
||||||
|
* 修复运行流水线后会闪烁一下的bug ([dfc9362](https://github.com/certd/certd/commit/dfc9362084082ee535b898f23b2609c1d946a6fd))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署plesk证书,支持删除未使用的证书 ([902d246](https://github.com/certd/certd/commit/902d246d1a7473ad90f604028c4eb09c8c67d99c))
|
||||||
|
* 通知和定时器的删除按钮显示为红色更显眼 ([61ba83c](https://github.com/certd/certd/commit/61ba83c77546c3d505d081e19a3d68c127662bf1))
|
||||||
|
* 优化流水线列表页面、详情页面性能,精简返回数据 ([609ac9c](https://github.com/certd/certd/commit/609ac9c9a2dde605eb09834ae59693c1cb238765))
|
||||||
|
* 支持自动选择校验方式申请证书 ([3f99432](https://github.com/certd/certd/commit/3f9943270cfb12946e38e6272bc5e8d95ad6ab9e))
|
||||||
|
* OpenAPI支持autoApply参数 ([42f4d14](https://github.com/certd/certd/commit/42f4d1477dc791520a874aed56035abcbc8c433b))
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
## 一、源码安装
|
## 一、源码安装
|
||||||
|
|
||||||
### 环境要求
|
### 环境要求
|
||||||
- nodejs 20 及以上
|
- nodejs 22 及以上
|
||||||
### 源码启动
|
### 源码启动
|
||||||
```shell
|
```shell
|
||||||
# 克隆代码
|
# 克隆代码
|
||||||
|
|||||||
BIN
docs/guide/use/tencent/images/opaque.png
Normal file
BIN
docs/guide/use/tencent/images/opaque.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 52 KiB |
BIN
docs/guide/use/tencent/images/tcpssl.png
Normal file
BIN
docs/guide/use/tencent/images/tcpssl.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 54 KiB |
@@ -8,8 +8,11 @@
|
|||||||

|

|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## 如何避免收到腾讯云证书过期邮件
|
## 如何避免收到腾讯云证书过期邮件
|
||||||
|
|
||||||
|
> 新版本已经自动将证书设置为免提醒,certd上传的证书后续都不会再提醒了。
|
||||||
|
|
||||||
腾讯云在证书有效期还剩28天时会发送过期通知邮件
|
腾讯云在证书有效期还剩28天时会发送过期通知邮件
|
||||||
您可以通过配置“腾讯云过期证书删除”任务来避免收到此类邮件。
|
您可以通过配置“腾讯云过期证书删除”任务来避免收到此类邮件。
|
||||||
|
|
||||||
@@ -19,3 +22,16 @@
|
|||||||
> 1. 选择腾讯云授权,需授权`服务角色SSL_QCSLinkedRoleInReplaceLoadCertificate`权限
|
> 1. 选择腾讯云授权,需授权`服务角色SSL_QCSLinkedRoleInReplaceLoadCertificate`权限
|
||||||
> 2. `1.26.14`版本之前Certd创建的证书流水线默认是到期前20天才更新证书,需要将之前创建的证书申请任务的更新天数修改为35天,保证删除之前就已经替换掉即将过期证书
|
> 2. `1.26.14`版本之前Certd创建的证书流水线默认是到期前20天才更新证书,需要将之前创建的证书申请任务的更新天数修改为35天,保证删除之前就已经替换掉即将过期证书
|
||||||

|

|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
## TKE service 的 TCP_SSL Opaque类型证书授权
|
||||||
|
|
||||||
|
部署证书到腾讯云TKE,如果报以下错误:
|
||||||
|
`is forbidden: User "xxxxxx-xxxxx" cannot get resource "secrets" in API group "" in the namespace "default"'`
|
||||||
|
则需要单独从授权管理侧再授权子用户的权限
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|

|
||||||
|
|||||||
@@ -9,5 +9,5 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"npmClient": "pnpm",
|
"npmClient": "pnpm",
|
||||||
"version": "1.36.5"
|
"version": "1.36.14"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,6 +36,7 @@
|
|||||||
},
|
},
|
||||||
"license": "AGPL-3.0",
|
"license": "AGPL-3.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@certd/ui-server": "link:packages/ui/certd-server",
|
||||||
"axios": "^1.7.7",
|
"axios": "^1.7.7",
|
||||||
"copyfiles": "^2.4.1",
|
"copyfiles": "^2.4.1",
|
||||||
"lodash-es": "^4.17.21",
|
"lodash-es": "^4.17.21",
|
||||||
|
|||||||
@@ -3,6 +3,38 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/publishlab/node-acme-client/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/publishlab/node-acme-client/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/publishlab/node-acme-client/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/publishlab/node-acme-client/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/publishlab/node-acme-client/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/publishlab/node-acme-client/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/publishlab/node-acme-client/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/publishlab/node-acme-client/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|
||||||
## [1.36.5](https://github.com/publishlab/node-acme-client/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/publishlab/node-acme-client/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/acme-client
|
**Note:** Version bump only for package @certd/acme-client
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
"description": "Simple and unopinionated ACME client",
|
"description": "Simple and unopinionated ACME client",
|
||||||
"private": false,
|
"private": false,
|
||||||
"author": "nmorsman",
|
"author": "nmorsman",
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"module": "scr/index.js",
|
"module": "scr/index.js",
|
||||||
"main": "src/index.js",
|
"main": "src/index.js",
|
||||||
@@ -18,7 +18,7 @@
|
|||||||
"types"
|
"types"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@certd/basic": "^1.36.5",
|
"@certd/basic": "^1.36.14",
|
||||||
"@peculiar/x509": "^1.11.0",
|
"@peculiar/x509": "^1.11.0",
|
||||||
"asn1js": "^3.0.5",
|
"asn1js": "^3.0.5",
|
||||||
"axios": "^1.7.2",
|
"axios": "^1.7.2",
|
||||||
@@ -69,5 +69,5 @@
|
|||||||
"bugs": {
|
"bugs": {
|
||||||
"url": "https://github.com/publishlab/node-acme-client/issues"
|
"url": "https://github.com/publishlab/node-acme-client/issues"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,6 +3,38 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/basic
|
**Note:** Version bump only for package @certd/basic
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
10:46
|
23:38
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/basic",
|
"name": "@certd/basic",
|
||||||
"private": false,
|
"private": false,
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"module": "./dist/index.js",
|
"module": "./dist/index.js",
|
||||||
@@ -45,5 +45,5 @@
|
|||||||
"tslib": "^2.8.1",
|
"tslib": "^2.8.1",
|
||||||
"typescript": "^5.4.2"
|
"typescript": "^5.4.2"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,6 +3,44 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/pipeline
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/pipeline
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复自定义插件onlyAdmin报错的bug ([4e5e862](https://github.com/certd/certd/commit/4e5e862f5834ad180e4428959c272d444a6f78ab))
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 安全更新,备份数据库插件仅限管理员运行 ([13dfca1](https://github.com/certd/certd/commit/13dfca1749275526c82465a17c482b607c820fdd))
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/pipeline
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/pipeline
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 支持邮箱发送证书 ([95332d5](https://github.com/certd/certd/commit/95332d5db96cd54ddab6ab737332417a09169b39))
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/pipeline
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/pipeline
|
**Note:** Version bump only for package @certd/pipeline
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/pipeline",
|
"name": "@certd/pipeline",
|
||||||
"private": false,
|
"private": false,
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"module": "./dist/index.js",
|
"module": "./dist/index.js",
|
||||||
@@ -17,8 +17,8 @@
|
|||||||
"pub": "npm publish"
|
"pub": "npm publish"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@certd/basic": "^1.36.5",
|
"@certd/basic": "^1.36.14",
|
||||||
"@certd/plus-core": "^1.36.5",
|
"@certd/plus-core": "^1.36.14",
|
||||||
"dayjs": "^1.11.7",
|
"dayjs": "^1.11.7",
|
||||||
"lodash-es": "^4.17.21",
|
"lodash-es": "^4.17.21",
|
||||||
"reflect-metadata": "^0.1.13"
|
"reflect-metadata": "^0.1.13"
|
||||||
@@ -44,5 +44,5 @@
|
|||||||
"tslib": "^2.8.1",
|
"tslib": "^2.8.1",
|
||||||
"typescript": "^5.4.2"
|
"typescript": "^5.4.2"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -352,6 +352,7 @@ export class Executor {
|
|||||||
pipeline: this.pipeline,
|
pipeline: this.pipeline,
|
||||||
runtime: this.runtime,
|
runtime: this.runtime,
|
||||||
step,
|
step,
|
||||||
|
define: cloneDeep(define),
|
||||||
lastStatus,
|
lastStatus,
|
||||||
http,
|
http,
|
||||||
download,
|
download,
|
||||||
|
|||||||
@@ -59,6 +59,7 @@ export type PluginDefine = Registrable & {
|
|||||||
form: any;
|
form: any;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
onlyAdmin?: boolean;
|
||||||
needPlus?: boolean;
|
needPlus?: boolean;
|
||||||
showRunStrategy?: boolean;
|
showRunStrategy?: boolean;
|
||||||
pluginType?: string; //类型
|
pluginType?: string; //类型
|
||||||
@@ -85,6 +86,7 @@ export type TaskInstanceContext = {
|
|||||||
runtime: RunHistory;
|
runtime: RunHistory;
|
||||||
//步骤定义
|
//步骤定义
|
||||||
step: Step;
|
step: Step;
|
||||||
|
define: PluginDefine;
|
||||||
//日志
|
//日志
|
||||||
logger: ILogger;
|
logger: ILogger;
|
||||||
//当前步骤输入参数跟上一次执行比较是否有变化
|
//当前步骤输入参数跟上一次执行比较是否有变化
|
||||||
@@ -162,6 +164,12 @@ export abstract class AbstractTaskPlugin implements ITaskPlugin {
|
|||||||
this.registerSecret(cert.key);
|
this.registerSecret(cert.key);
|
||||||
this.registerSecret(cert.one);
|
this.registerSecret(cert.one);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (this.ctx?.define?.onlyAdmin) {
|
||||||
|
if (!this.isAdmin()) {
|
||||||
|
throw new Error("只有管理员才能运行此任务");
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async getAccess<T = any>(accessId: string | number, isCommon = false) {
|
async getAccess<T = any>(accessId: string | number, isCommon = false) {
|
||||||
|
|||||||
@@ -30,4 +30,5 @@ export const pluginGroups = {
|
|||||||
qiniu: new PluginGroup("qiniu", "七牛云", 5, "svg:icon-qiniuyun"),
|
qiniu: new PluginGroup("qiniu", "七牛云", 5, "svg:icon-qiniuyun"),
|
||||||
aws: new PluginGroup("aws", "亚马逊云", 6, "svg:icon-aws"),
|
aws: new PluginGroup("aws", "亚马逊云", 6, "svg:icon-aws"),
|
||||||
other: new PluginGroup("other", "其他", 10, "clarity:plugin-line"),
|
other: new PluginGroup("other", "其他", 10, "clarity:plugin-line"),
|
||||||
|
admin: new PluginGroup("admin", "管理", 11, "ion:settings-outline"),
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
export type EmailSend = {
|
export type EmailSend = {
|
||||||
subject: string;
|
subject: string;
|
||||||
content: string;
|
|
||||||
receivers: string[];
|
receivers: string[];
|
||||||
|
content?: string;
|
||||||
|
attachments?: any[];
|
||||||
|
html?: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export interface IEmailService {
|
export interface IEmailService {
|
||||||
|
|||||||
@@ -3,6 +3,38 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/lib-huawei
|
**Note:** Version bump only for package @certd/lib-huawei
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/lib-huawei",
|
"name": "@certd/lib-huawei",
|
||||||
"private": false,
|
"private": false,
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"main": "./dist/bundle.js",
|
"main": "./dist/bundle.js",
|
||||||
"module": "./dist/bundle.js",
|
"module": "./dist/bundle.js",
|
||||||
"types": "./dist/d/index.d.ts",
|
"types": "./dist/d/index.d.ts",
|
||||||
@@ -24,5 +24,5 @@
|
|||||||
"prettier": "^2.8.8",
|
"prettier": "^2.8.8",
|
||||||
"tslib": "^2.8.1"
|
"tslib": "^2.8.1"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,6 +3,38 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/lib-iframe
|
**Note:** Version bump only for package @certd/lib-iframe
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/lib-iframe",
|
"name": "@certd/lib-iframe",
|
||||||
"private": false,
|
"private": false,
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"module": "./dist/index.js",
|
"module": "./dist/index.js",
|
||||||
@@ -31,5 +31,5 @@
|
|||||||
"tslib": "^2.8.1",
|
"tslib": "^2.8.1",
|
||||||
"typescript": "^5.4.2"
|
"typescript": "^5.4.2"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,6 +3,38 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/jdcloud
|
**Note:** Version bump only for package @certd/jdcloud
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/jdcloud",
|
"name": "@certd/jdcloud",
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"description": "jdcloud openApi sdk",
|
"description": "jdcloud openApi sdk",
|
||||||
"main": "./dist/bundle.js",
|
"main": "./dist/bundle.js",
|
||||||
"module": "./dist/bundle.js",
|
"module": "./dist/bundle.js",
|
||||||
@@ -61,5 +61,5 @@
|
|||||||
"fetch"
|
"fetch"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,6 +3,42 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* k8s ack、tke 支持重启ingress ([95715a0](https://github.com/certd/certd/commit/95715a007d931c64fa7dd953d94957398e00a443))
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-k8s
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署到k8s,tke,ack忽悠证书校验 ([ab84835](https://github.com/certd/certd/commit/ab848353621869464a2c9a45fdb5e28d998b8a58))
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-k8s
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-k8s
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-k8s
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-k8s
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-k8s
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/lib-k8s
|
**Note:** Version bump only for package @certd/lib-k8s
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/lib-k8s",
|
"name": "@certd/lib-k8s",
|
||||||
"private": false,
|
"private": false,
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"module": "./dist/index.js",
|
"module": "./dist/index.js",
|
||||||
@@ -17,7 +17,7 @@
|
|||||||
"pub": "npm publish"
|
"pub": "npm publish"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@certd/basic": "^1.36.5",
|
"@certd/basic": "^1.36.14",
|
||||||
"@kubernetes/client-node": "0.21.0"
|
"@kubernetes/client-node": "0.21.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
@@ -32,5 +32,5 @@
|
|||||||
"tslib": "^2.8.1",
|
"tslib": "^2.8.1",
|
||||||
"typescript": "^5.4.2"
|
"typescript": "^5.4.2"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
export * from './lib/k8s.client.js';
|
export * from "./lib/k8s.client.js";
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { CoreV1Api, KubeConfig, NetworkingV1Api, V1Ingress, V1Secret } from '@kubernetes/client-node';
|
import { CoreV1Api, KubeConfig, NetworkingV1Api, V1Ingress, V1Secret } from "@kubernetes/client-node";
|
||||||
import dns from 'dns';
|
import dns from "dns";
|
||||||
import { ILogger } from '@certd/basic';
|
import { ILogger } from "@certd/basic";
|
||||||
import _ from 'lodash-es';
|
import _ from "lodash-es";
|
||||||
|
|
||||||
export type K8sClientOpts = {
|
export type K8sClientOpts = {
|
||||||
kubeConfigStr: string;
|
kubeConfigStr: string;
|
||||||
@@ -9,6 +9,7 @@ export type K8sClientOpts = {
|
|||||||
//{ [domain]:{ip:'xxx.xx.xxx'} }
|
//{ [domain]:{ip:'xxx.xx.xxx'} }
|
||||||
//暂时没用
|
//暂时没用
|
||||||
lookup?: any;
|
lookup?: any;
|
||||||
|
skipTLSVerify?: boolean;
|
||||||
};
|
};
|
||||||
export class K8sClient {
|
export class K8sClient {
|
||||||
kubeconfig!: KubeConfig;
|
kubeconfig!: KubeConfig;
|
||||||
@@ -16,10 +17,12 @@ export class K8sClient {
|
|||||||
lookup!: (hostnameReq: any, options: any, callback: any) => void;
|
lookup!: (hostnameReq: any, options: any, callback: any) => void;
|
||||||
client!: CoreV1Api;
|
client!: CoreV1Api;
|
||||||
logger: ILogger;
|
logger: ILogger;
|
||||||
|
skipTLSVerify?: boolean;
|
||||||
constructor(opts: K8sClientOpts) {
|
constructor(opts: K8sClientOpts) {
|
||||||
this.kubeConfigStr = opts.kubeConfigStr;
|
this.kubeConfigStr = opts.kubeConfigStr;
|
||||||
this.logger = opts.logger;
|
this.logger = opts.logger;
|
||||||
this.setLookup(opts.lookup);
|
this.setLookup(opts.lookup);
|
||||||
|
this.skipTLSVerify = opts.skipTLSVerify;
|
||||||
this.init();
|
this.init();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -27,6 +30,18 @@ export class K8sClient {
|
|||||||
const kubeconfig = new KubeConfig();
|
const kubeconfig = new KubeConfig();
|
||||||
kubeconfig.loadFromString(this.kubeConfigStr);
|
kubeconfig.loadFromString(this.kubeConfigStr);
|
||||||
this.kubeconfig = kubeconfig;
|
this.kubeconfig = kubeconfig;
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (this.skipTLSVerify == true) {
|
||||||
|
for (const cluster of kubeconfig.getClusters()) {
|
||||||
|
// @ts-ignore
|
||||||
|
cluster["skipTLSVerify"] = this.skipTLSVerify;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
this.logger.warn("skipTLSVerify error", e);
|
||||||
|
}
|
||||||
|
|
||||||
this.client = kubeconfig.makeApiClient(CoreV1Api);
|
this.client = kubeconfig.makeApiClient(CoreV1Api);
|
||||||
|
|
||||||
// const reqOpts = { kubeconfig, request: {} } as any;
|
// const reqOpts = { kubeconfig, request: {} } as any;
|
||||||
@@ -47,9 +62,9 @@ export class K8sClient {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this.lookup = (hostnameReq: any, options: any, callback: any) => {
|
this.lookup = (hostnameReq: any, options: any, callback: any) => {
|
||||||
this.logger.info('custom lookup', hostnameReq, localRecords);
|
this.logger.info("custom lookup", hostnameReq, localRecords);
|
||||||
if (localRecords[hostnameReq]) {
|
if (localRecords[hostnameReq]) {
|
||||||
this.logger.info('local record', hostnameReq, localRecords[hostnameReq]);
|
this.logger.info("local record", hostnameReq, localRecords[hostnameReq]);
|
||||||
callback(null, localRecords[hostnameReq].ip, 4);
|
callback(null, localRecords[hostnameReq].ip, 4);
|
||||||
} else {
|
} else {
|
||||||
dns.lookup(hostnameReq, options, callback);
|
dns.lookup(hostnameReq, options, callback);
|
||||||
@@ -63,7 +78,7 @@ export class K8sClient {
|
|||||||
* @returns secretsList
|
* @returns secretsList
|
||||||
*/
|
*/
|
||||||
async getSecrets(opts: { namespace: string }) {
|
async getSecrets(opts: { namespace: string }) {
|
||||||
const namespace = opts.namespace || 'default';
|
const namespace = opts.namespace || "default";
|
||||||
return await this.client.listNamespacedSecret(namespace);
|
return await this.client.listNamespacedSecret(namespace);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -73,9 +88,9 @@ export class K8sClient {
|
|||||||
* @returns {Promise<*>}
|
* @returns {Promise<*>}
|
||||||
*/
|
*/
|
||||||
async createSecret(opts: { namespace: string; body: V1Secret }) {
|
async createSecret(opts: { namespace: string; body: V1Secret }) {
|
||||||
const namespace = opts.namespace || 'default';
|
const namespace = opts.namespace || "default";
|
||||||
const created = await this.client.createNamespacedSecret(namespace, opts.body);
|
const created = await this.client.createNamespacedSecret(namespace, opts.body);
|
||||||
this.logger.info('new secrets:', opts.body);
|
this.logger.info("new secrets:", opts.body);
|
||||||
return created.body;
|
return created.body;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -89,24 +104,24 @@ export class K8sClient {
|
|||||||
// }
|
// }
|
||||||
|
|
||||||
async patchSecret(opts: { namespace: string; secretName: string; body: V1Secret }) {
|
async patchSecret(opts: { namespace: string; secretName: string; body: V1Secret }) {
|
||||||
const namespace = opts.namespace || 'default';
|
const namespace = opts.namespace || "default";
|
||||||
const secretName = opts.secretName;
|
const secretName = opts.secretName;
|
||||||
if (secretName == null) {
|
if (secretName == null) {
|
||||||
throw new Error('secretName 不能为空');
|
throw new Error("secretName 不能为空");
|
||||||
}
|
}
|
||||||
this.logger.info('patch secret:', secretName, namespace);
|
this.logger.info("patch secret:", secretName, namespace);
|
||||||
const oldSecret = await this.client.readNamespacedSecret(secretName, namespace);
|
const oldSecret = await this.client.readNamespacedSecret(secretName, namespace);
|
||||||
const newSecret = _.merge(oldSecret.body, opts.body);
|
const newSecret = _.merge(oldSecret.body, opts.body);
|
||||||
const res = await this.client.replaceNamespacedSecret(secretName, namespace, newSecret);
|
const res = await this.client.replaceNamespacedSecret(secretName, namespace, newSecret);
|
||||||
this.logger.info('secret updated');
|
this.logger.info("secret updated");
|
||||||
return res.body;
|
return res.body;
|
||||||
}
|
}
|
||||||
|
|
||||||
async getIngressList(opts: { namespace: string }) {
|
async getIngressList(opts: { namespace: string }) {
|
||||||
const namespace = opts.namespace || 'default';
|
const namespace = opts.namespace || "default";
|
||||||
const client = this.kubeconfig.makeApiClient(NetworkingV1Api);
|
const client = this.kubeconfig.makeApiClient(NetworkingV1Api);
|
||||||
const res = await client.listNamespacedIngress(namespace);
|
const res = await client.listNamespacedIngress(namespace);
|
||||||
this.logger.info('ingress list get:', res.body);
|
this.logger.info("ingress list get:", res.body);
|
||||||
return res.body;
|
return res.body;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -122,17 +137,31 @@ export class K8sClient {
|
|||||||
// }
|
// }
|
||||||
|
|
||||||
async patchIngress(opts: { namespace: string; ingressName: string; body: V1Ingress }) {
|
async patchIngress(opts: { namespace: string; ingressName: string; body: V1Ingress }) {
|
||||||
const namespace = opts.namespace || 'default';
|
const namespace = opts.namespace || "default";
|
||||||
const ingressName = opts.ingressName;
|
const ingressName = opts.ingressName;
|
||||||
if (!ingressName) {
|
if (!ingressName) {
|
||||||
throw new Error('ingressName 不能为空');
|
throw new Error("ingressName 不能为空");
|
||||||
}
|
}
|
||||||
this.logger.info('patch ingress:', ingressName, namespace);
|
this.logger.info("patch ingress:", ingressName, namespace);
|
||||||
const client = this.kubeconfig.makeApiClient(NetworkingV1Api);
|
const client = this.kubeconfig.makeApiClient(NetworkingV1Api);
|
||||||
const oldIngress = await client.readNamespacedIngress(ingressName, namespace);
|
const oldIngress = await client.readNamespacedIngress(ingressName, namespace);
|
||||||
const newIngress = _.merge(oldIngress.body, opts.body);
|
const newIngress = _.merge(oldIngress.body, opts.body);
|
||||||
const res = await client.replaceNamespacedIngress(ingressName, namespace, newIngress);
|
const res = await client.replaceNamespacedIngress(ingressName, namespace, newIngress);
|
||||||
this.logger.info('ingress patched', opts.body);
|
this.logger.info("ingress patched", opts.body);
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async restartIngress(namespace: string, ingressNames: string[], labels: any) {
|
||||||
|
const body = {
|
||||||
|
metadata: {
|
||||||
|
labels: {
|
||||||
|
...labels,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
|
for (const ingress of ingressNames) {
|
||||||
|
await this.patchIngress({ namespace, ingressName: ingress, body });
|
||||||
|
this.logger.info(`ingress已重启:${ingress}`);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,6 +3,43 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 新增找回密码功能 [@nicheng-he](https://github.com/nicheng-he) ([81ac240](https://github.com/certd/certd/commit/81ac240ac84db0af2f56b6352e227ecb49f38377))
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-server
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-server
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-server
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-server
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-server
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/lib-server
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 优化流水线列表页面、详情页面性能,精简返回数据 ([609ac9c](https://github.com/certd/certd/commit/609ac9c9a2dde605eb09834ae59693c1cb238765))
|
||||||
|
* OpenAPI支持autoApply参数 ([42f4d14](https://github.com/certd/certd/commit/42f4d1477dc791520a874aed56035abcbc8c433b))
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/lib-server
|
**Note:** Version bump only for package @certd/lib-server
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/lib-server",
|
"name": "@certd/lib-server",
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"description": "midway with flyway, sql upgrade way ",
|
"description": "midway with flyway, sql upgrade way ",
|
||||||
"private": false,
|
"private": false,
|
||||||
"type": "module",
|
"type": "module",
|
||||||
@@ -27,10 +27,10 @@
|
|||||||
],
|
],
|
||||||
"license": "AGPL",
|
"license": "AGPL",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@certd/acme-client": "^1.36.5",
|
"@certd/acme-client": "^1.36.14",
|
||||||
"@certd/basic": "^1.36.5",
|
"@certd/basic": "^1.36.14",
|
||||||
"@certd/pipeline": "^1.36.5",
|
"@certd/pipeline": "^1.36.14",
|
||||||
"@certd/plus-core": "^1.36.5",
|
"@certd/plus-core": "^1.36.14",
|
||||||
"@midwayjs/cache": "~3.14.0",
|
"@midwayjs/cache": "~3.14.0",
|
||||||
"@midwayjs/core": "~3.20.3",
|
"@midwayjs/core": "~3.20.3",
|
||||||
"@midwayjs/i18n": "~3.20.3",
|
"@midwayjs/i18n": "~3.20.3",
|
||||||
@@ -61,5 +61,5 @@
|
|||||||
"typeorm": "^0.3.11",
|
"typeorm": "^0.3.11",
|
||||||
"typescript": "^5.4.2"
|
"typescript": "^5.4.2"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -164,8 +164,11 @@ export abstract class BaseService<T> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private buildListQuery(listReq: ListReq<T>) {
|
private buildListQuery(listReq: ListReq<T>) {
|
||||||
const { query, sort, buildQuery } = listReq;
|
const { query, sort, buildQuery,select } = listReq;
|
||||||
const qb = this.getRepository().createQueryBuilder('main');
|
const qb = this.getRepository().createQueryBuilder('main');
|
||||||
|
if (select) {
|
||||||
|
qb.setFindOptions({select});
|
||||||
|
}
|
||||||
if (query) {
|
if (query) {
|
||||||
const keys = Object.keys(query);
|
const keys = Object.keys(query);
|
||||||
for (const key of keys) {
|
for (const key of keys) {
|
||||||
@@ -191,6 +194,7 @@ export abstract class BaseService<T> {
|
|||||||
if (buildQuery) {
|
if (buildQuery) {
|
||||||
buildQuery(qb);
|
buildQuery(qb);
|
||||||
}
|
}
|
||||||
|
|
||||||
return qb;
|
return qb;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -107,5 +107,17 @@ export const Constants = {
|
|||||||
code: 20012,
|
code: 20012,
|
||||||
message: '证书还未生成',
|
message: '证书还未生成',
|
||||||
},
|
},
|
||||||
|
openCertApplying: {
|
||||||
|
code: 20013,
|
||||||
|
message: '证书正在申请中,请稍后重新获取',
|
||||||
|
},
|
||||||
|
openDomainNoVerifier:{
|
||||||
|
code: 20014,
|
||||||
|
message: '域名校验方式未配置',
|
||||||
|
},
|
||||||
|
openEmailNotFound: {
|
||||||
|
code: 20021,
|
||||||
|
message: '用户邮箱还未配置',
|
||||||
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -11,13 +11,13 @@ export class CommonException extends BaseException {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export class CodeException extends BaseException {
|
export class CodeException extends BaseException {
|
||||||
constructor(res: { code: number; message: string }) {
|
constructor(res: { code: number; message: string; data?: any }) {
|
||||||
super("CodeException", res.code, res.message);
|
super("CodeException", res.code, res.message, res.data);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export class TextException extends BaseException {
|
export class TextException extends BaseException {
|
||||||
constructor(name, code,message, data?) {
|
constructor(name, code, message, data?) {
|
||||||
super(name, code, message, data);
|
super(name, code, message, data);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ export class SysPublicSettings extends BaseSettings {
|
|||||||
mobileRegisterEnabled = false;
|
mobileRegisterEnabled = false;
|
||||||
smsLoginEnabled = false;
|
smsLoginEnabled = false;
|
||||||
emailRegisterEnabled = false;
|
emailRegisterEnabled = false;
|
||||||
|
selfServicePasswordRetrievalEnabled = false;
|
||||||
|
|
||||||
limitUserPipelineCount = 0;
|
limitUserPipelineCount = 0;
|
||||||
managerOtherUserPipeline = false;
|
managerOtherUserPipeline = false;
|
||||||
|
|||||||
@@ -3,6 +3,38 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/midway-flyway-js
|
**Note:** Version bump only for package @certd/midway-flyway-js
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/midway-flyway-js",
|
"name": "@certd/midway-flyway-js",
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"description": "midway with flyway, sql upgrade way ",
|
"description": "midway with flyway, sql upgrade way ",
|
||||||
"private": false,
|
"private": false,
|
||||||
"type": "module",
|
"type": "module",
|
||||||
@@ -46,5 +46,5 @@
|
|||||||
"typeorm": "^0.3.11",
|
"typeorm": "^0.3.11",
|
||||||
"typescript": "^5.4.2"
|
"typescript": "^5.4.2"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,6 +3,45 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复商用证书上传第二次运行无法使用pfx格式证书的bug ([251dd1f](https://github.com/certd/certd/commit/251dd1fe457a7b152f43eb6de18f7beb9f0b194e))
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-cert
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-cert
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-cert
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-cert
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-cert
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 支持邮箱发送证书 ([95332d5](https://github.com/certd/certd/commit/95332d5db96cd54ddab6ab737332417a09169b39))
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 支持自动选择校验方式申请证书 ([3f99432](https://github.com/certd/certd/commit/3f9943270cfb12946e38e6272bc5e8d95ad6ab9e))
|
||||||
|
* OpenAPI支持autoApply参数 ([42f4d14](https://github.com/certd/certd/commit/42f4d1477dc791520a874aed56035abcbc8c433b))
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/plugin-cert
|
**Note:** Version bump only for package @certd/plugin-cert
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/plugin-cert",
|
"name": "@certd/plugin-cert",
|
||||||
"private": false,
|
"private": false,
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"types": "./dist/index.d.ts",
|
"types": "./dist/index.d.ts",
|
||||||
@@ -16,10 +16,10 @@
|
|||||||
"pub": "npm publish"
|
"pub": "npm publish"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@certd/acme-client": "^1.36.5",
|
"@certd/acme-client": "^1.36.14",
|
||||||
"@certd/basic": "^1.36.5",
|
"@certd/basic": "^1.36.14",
|
||||||
"@certd/pipeline": "^1.36.5",
|
"@certd/pipeline": "^1.36.14",
|
||||||
"@certd/plugin-lib": "^1.36.5",
|
"@certd/plugin-lib": "^1.36.14",
|
||||||
"@google-cloud/publicca": "^1.3.0",
|
"@google-cloud/publicca": "^1.3.0",
|
||||||
"dayjs": "^1.11.7",
|
"dayjs": "^1.11.7",
|
||||||
"jszip": "^3.10.1",
|
"jszip": "^3.10.1",
|
||||||
@@ -43,5 +43,5 @@
|
|||||||
"tslib": "^2.8.1",
|
"tslib": "^2.8.1",
|
||||||
"typescript": "^5.4.2"
|
"typescript": "^5.4.2"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { AbstractTaskPlugin, IContext, Step, TaskInput, TaskOutput } from "@certd/pipeline";
|
import { AbstractTaskPlugin, FileItem, IContext, Step, TaskInput, TaskOutput } from "@certd/pipeline";
|
||||||
import dayjs from "dayjs";
|
import dayjs from "dayjs";
|
||||||
import type { CertInfo } from "./acme.js";
|
import type { CertInfo } from "./acme.js";
|
||||||
import { CertReader } from "./cert-reader.js";
|
import { CertReader } from "./cert-reader.js";
|
||||||
@@ -71,6 +71,12 @@ export abstract class CertApplyBaseConvertPlugin extends AbstractTaskPlugin {
|
|||||||
})
|
})
|
||||||
cert?: CertInfo;
|
cert?: CertInfo;
|
||||||
|
|
||||||
|
@TaskOutput({
|
||||||
|
title: "域名证书压缩文件",
|
||||||
|
type: "certZip",
|
||||||
|
})
|
||||||
|
certZip?: FileItem;
|
||||||
|
|
||||||
async onInstance() {
|
async onInstance() {
|
||||||
this.userContext = this.ctx.userContext;
|
this.userContext = this.ctx.userContext;
|
||||||
this.lastStatus = this.ctx.lastStatus as Step;
|
this.lastStatus = this.ctx.lastStatus as Step;
|
||||||
@@ -131,6 +137,7 @@ export abstract class CertApplyBaseConvertPlugin extends AbstractTaskPlugin {
|
|||||||
} else {
|
} else {
|
||||||
this.extendsFiles();
|
this.extendsFiles();
|
||||||
}
|
}
|
||||||
|
this.certZip = this._result.files[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
async zipCert(cert: CertInfo, filename: string) {
|
async zipCert(cert: CertInfo, filename: string) {
|
||||||
@@ -187,4 +194,13 @@ cert.jks:jks格式证书文件,java服务器使用
|
|||||||
};
|
};
|
||||||
return newCert;
|
return newCert;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async readLastCert(): Promise<CertReader | undefined> {
|
||||||
|
const cert = this.lastStatus?.status?.output?.cert;
|
||||||
|
if (cert == null) {
|
||||||
|
this.logger.info("没有找到上次的证书");
|
||||||
|
return undefined;
|
||||||
|
}
|
||||||
|
return new CertReader(cert);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -130,15 +130,6 @@ export abstract class CertApplyBasePlugin extends CertApplyBaseConvertPlugin {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
async readLastCert(): Promise<CertReader | undefined> {
|
|
||||||
const cert = this.lastStatus?.status?.output?.cert;
|
|
||||||
if (cert == null) {
|
|
||||||
this.logger.info("没有找到上次的证书");
|
|
||||||
return undefined;
|
|
||||||
}
|
|
||||||
return new CertReader(cert);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 检查是否过期,默认提前35天
|
* 检查是否过期,默认提前35天
|
||||||
* @param expires
|
* @param expires
|
||||||
|
|||||||
@@ -100,8 +100,17 @@ export class CertApplyUploadPlugin extends CertApplyBaseConvertPlugin {
|
|||||||
async onInit(): Promise<void> {}
|
async onInit(): Promise<void> {}
|
||||||
|
|
||||||
async getCertFromStore() {
|
async getCertFromStore() {
|
||||||
const certReader = new CertReader(this.uploadCert);
|
let certReader = null;
|
||||||
if (!certReader.expires && certReader.expires < new Date().getTime()) {
|
try {
|
||||||
|
this.logger.info("读取上次证书");
|
||||||
|
certReader = await this.readLastCert();
|
||||||
|
} catch (e) {
|
||||||
|
this.logger.warn("读取cert失败:", e);
|
||||||
|
}
|
||||||
|
if (certReader == null) {
|
||||||
|
certReader = new CertReader(this.uploadCert);
|
||||||
|
}
|
||||||
|
if (!certReader.expires || certReader.expires < new Date().getTime()) {
|
||||||
throw new Error("证书已过期,停止部署,请重新上传证书");
|
throw new Error("证书已过期,停止部署,请重新上传证书");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -470,6 +470,9 @@ export class CertApplyPlugin extends CertApplyBasePlugin {
|
|||||||
const domain = fullDomain.replaceAll("*.", "");
|
const domain = fullDomain.replaceAll("*.", "");
|
||||||
const mainDomain = await domainParser.parse(domain);
|
const mainDomain = await domainParser.parse(domain);
|
||||||
const planSetting: DomainVerifyPlanInput = verifyPlanSetting[mainDomain];
|
const planSetting: DomainVerifyPlanInput = verifyPlanSetting[mainDomain];
|
||||||
|
if (planSetting == null) {
|
||||||
|
throw new Error(`没有找到域名(${domain})的校验计划`);
|
||||||
|
}
|
||||||
if (planSetting.type === "dns") {
|
if (planSetting.type === "dns") {
|
||||||
plan[domain] = await this.createDnsDomainVerifyPlan(planSetting, domain, mainDomain);
|
plan[domain] = await this.createDnsDomainVerifyPlan(planSetting, domain, mainDomain);
|
||||||
} else if (planSetting.type === "cname") {
|
} else if (planSetting.type === "cname") {
|
||||||
@@ -498,6 +501,9 @@ export class CertApplyPlugin extends CertApplyBasePlugin {
|
|||||||
|
|
||||||
for (const domain in verifiers) {
|
for (const domain in verifiers) {
|
||||||
const verifier = verifiers[domain];
|
const verifier = verifiers[domain];
|
||||||
|
if (verifier == null) {
|
||||||
|
throw new Error(`没有找到与该域名(${domain})匹配的校验方式,请先到‘域名管理’页面添加校验方式`);
|
||||||
|
}
|
||||||
if (verifier.type === "dns") {
|
if (verifier.type === "dns") {
|
||||||
plan[domain] = await this.createDnsDomainVerifyPlan(verifier.dns, domain, verifier.mainDomain);
|
plan[domain] = await this.createDnsDomainVerifyPlan(verifier.dns, domain, verifier.mainDomain);
|
||||||
} else if (verifier.type === "cname") {
|
} else if (verifier.type === "cname") {
|
||||||
|
|||||||
@@ -3,6 +3,46 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 1panel支持 currenNode ([acc8907](https://github.com/certd/certd/commit/acc890730f43d492c9b1bd3668814cf10efdf7b8))
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复阿里云发送短信验证码失败的bug ([2e6d03f](https://github.com/certd/certd/commit/2e6d03ff001f521f57368e7a62b97ed7b122e8d0))
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-lib
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-lib
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-lib
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复ssh无法执行命令的bug ([9763cb0](https://github.com/certd/certd/commit/9763cb00e5d95b2fa5d1c2d3d4a8eecac71600e6))
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复流水线页面状态没有刷新的bug ([93e9498](https://github.com/certd/certd/commit/93e9498b410353f504e11e264db62468895d7290))
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/plugin-lib
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/plugin-lib
|
**Note:** Version bump only for package @certd/plugin-lib
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/plugin-lib",
|
"name": "@certd/plugin-lib",
|
||||||
"private": false,
|
"private": false,
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"types": "./dist/index.d.ts",
|
"types": "./dist/index.d.ts",
|
||||||
@@ -21,8 +21,8 @@
|
|||||||
"@alicloud/pop-core": "^1.7.10",
|
"@alicloud/pop-core": "^1.7.10",
|
||||||
"@alicloud/tea-util": "^1.4.10",
|
"@alicloud/tea-util": "^1.4.10",
|
||||||
"@aws-sdk/client-s3": "^3.787.0",
|
"@aws-sdk/client-s3": "^3.787.0",
|
||||||
"@certd/basic": "^1.36.5",
|
"@certd/basic": "^1.36.14",
|
||||||
"@certd/pipeline": "^1.36.5",
|
"@certd/pipeline": "^1.36.14",
|
||||||
"@kubernetes/client-node": "0.21.0",
|
"@kubernetes/client-node": "0.21.0",
|
||||||
"ali-oss": "^6.22.0",
|
"ali-oss": "^6.22.0",
|
||||||
"basic-ftp": "^5.0.5",
|
"basic-ftp": "^5.0.5",
|
||||||
@@ -53,5 +53,5 @@
|
|||||||
"tslib": "^2.8.1",
|
"tslib": "^2.8.1",
|
||||||
"typescript": "^5.4.2"
|
"typescript": "^5.4.2"
|
||||||
},
|
},
|
||||||
"gitHead": "c2a95a13fe6edf05ea0f72f5f7c76f9eea3ab0bd"
|
"gitHead": "1e03a2e553aa94982453a477d2a0d35a565b6270"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ export class AliyunClient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
checkRet(ret: any) {
|
checkRet(ret: any) {
|
||||||
if (ret.Code != null) {
|
if (ret.Code != null && ret.Code !== "OK" && ret.Message !== "OK") {
|
||||||
throw new Error("执行失败:" + ret.Message);
|
throw new Error("执行失败:" + ret.Message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ export function createCertDomainGetterInputDefine(opts?: { certInputKey?: string
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
`,
|
`,
|
||||||
template:false,
|
template: false,
|
||||||
required: true,
|
required: true,
|
||||||
},
|
},
|
||||||
opts?.props
|
opts?.props
|
||||||
@@ -42,6 +42,7 @@ export function createRemoteSelectInputDefine(opts?: {
|
|||||||
search?: boolean;
|
search?: boolean;
|
||||||
pager?: boolean;
|
pager?: boolean;
|
||||||
component?: any;
|
component?: any;
|
||||||
|
value?: any;
|
||||||
}) {
|
}) {
|
||||||
const title = opts?.title || "请选择";
|
const title = opts?.title || "请选择";
|
||||||
const certDomainsInputKey = opts?.certDomainsInputKey || "certDomains";
|
const certDomainsInputKey = opts?.certDomainsInputKey || "certDomains";
|
||||||
@@ -74,6 +75,7 @@ export function createRemoteSelectInputDefine(opts?: {
|
|||||||
watches: [certDomainsInputKey, accessIdInputKey, ...watches],
|
watches: [certDomainsInputKey, accessIdInputKey, ...watches],
|
||||||
...opts.component,
|
...opts.component,
|
||||||
},
|
},
|
||||||
|
value: opts.value,
|
||||||
rules: opts?.rules,
|
rules: opts?.rules,
|
||||||
required: opts.required ?? true,
|
required: opts.required ?? true,
|
||||||
mergeScript:
|
mergeScript:
|
||||||
|
|||||||
@@ -16,6 +16,10 @@ export default class SshOssClientImpl extends BaseOssClient<SshAccess> {
|
|||||||
throw new Error("Method not implemented.");
|
throw new Error("Method not implemented.");
|
||||||
}
|
}
|
||||||
async upload(filePath: string, fileContent: Buffer) {
|
async upload(filePath: string, fileContent: Buffer) {
|
||||||
|
if (!filePath) {
|
||||||
|
filePath = "";
|
||||||
|
}
|
||||||
|
filePath = filePath.trim();
|
||||||
const tmpFilePath = path.join(os.tmpdir(), "cert", "http", filePath);
|
const tmpFilePath = path.join(os.tmpdir(), "cert", "http", filePath);
|
||||||
|
|
||||||
// Write file to temp path
|
// Write file to temp path
|
||||||
|
|||||||
@@ -506,10 +506,6 @@ export class SshClient {
|
|||||||
isWinCmd = await this.isCmd(conn);
|
isWinCmd = await this.isCmd(conn);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isLinux && options.stopOnError !== false) {
|
|
||||||
script = "set -e\n" + script;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (options.env) {
|
if (options.env) {
|
||||||
for (const key in options.env) {
|
for (const key in options.env) {
|
||||||
if (isLinux) {
|
if (isLinux) {
|
||||||
@@ -525,10 +521,10 @@ export class SshClient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (isWinCmd) {
|
if (isWinCmd) {
|
||||||
//组合成&&的形式
|
|
||||||
if (typeof script === "string") {
|
if (typeof script === "string") {
|
||||||
script = script.split("\n");
|
script = script.split("\n");
|
||||||
}
|
}
|
||||||
|
//组合成&&的形式
|
||||||
script = envScripts.concat(script);
|
script = envScripts.concat(script);
|
||||||
script = script as Array<string>;
|
script = script as Array<string>;
|
||||||
script = script.join(" && ");
|
script = script.join(" && ");
|
||||||
@@ -543,6 +539,10 @@ export class SshClient {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (isLinux && options.stopOnError !== false) {
|
||||||
|
script = "set -e\n" + script;
|
||||||
|
}
|
||||||
|
|
||||||
return await conn.exec(script as string, { throwOnStdErr });
|
return await conn.exec(script as string, { throwOnStdErr });
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
1
packages/ui/certd-client/.gitignore
vendored
1
packages/ui/certd-client/.gitignore
vendored
@@ -9,3 +9,4 @@ yarn.lock
|
|||||||
/.idea/
|
/.idea/
|
||||||
yarn-error.log
|
yarn-error.log
|
||||||
vite-profile.cpuprofile
|
vite-profile.cpuprofile
|
||||||
|
!build
|
||||||
@@ -3,6 +3,69 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复复制流水线为空的bug ([b070773](https://github.com/certd/certd/commit/b0707739fdfbae3d78db4efd3f180db05c4e4164))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 授权管理支持模糊查询 ([866eb62](https://github.com/certd/certd/commit/866eb6241baa7b21f6eddc649966324c188236c6))
|
||||||
|
* 新增找回密码功能 [@nicheng-he](https://github.com/nicheng-he) ([81ac240](https://github.com/certd/certd/commit/81ac240ac84db0af2f56b6352e227ecb49f38377))
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 阿里云部分插件优化 [@nicheng-he](https://github.com/nicheng-he) ([e3738f6](https://github.com/certd/certd/commit/e3738f6422270d75ec414c15a343248cc4cad6e1))
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 上传到阿里云cas,证书前缀无效的bug ([b382351](https://github.com/certd/certd/commit/b382351c7b91ec10e1f61d94bec5aad075207ec8))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 首页增加更新日志按钮 ([41ce848](https://github.com/certd/certd/commit/41ce8489dc2f03a705dfa3fbb357769defb56c60))
|
||||||
|
* 增加版本过低提示 ([d1ce360](https://github.com/certd/certd/commit/d1ce36038cab72b5dc1b320d0a708c261ffbdacb))
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/ui-client
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 优化子域名托管的说明 ([b15f514](https://github.com/certd/certd/commit/b15f514018b728acb0922ee3f93c1f302eb5d471))
|
||||||
|
* 账号即将过期通知 ([e403450](https://github.com/certd/certd/commit/e40345095f31e2fb8e2333a6647466659133fa0c))
|
||||||
|
* 子域名托管重复域名不允许添加 ([ffc0c7b](https://github.com/certd/certd/commit/ffc0c7bb7b16d9904fd2d905d1c4e1d4854e92a9))
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/ui-client
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复流水线页面状态没有刷新的bug ([93e9498](https://github.com/certd/certd/commit/93e9498b410353f504e11e264db62468895d7290))
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复某些页面翻译不全显示错误的bug ([0b3158f](https://github.com/certd/certd/commit/0b3158fdd5fe5bb0a98c4e65715dbc3de2c38047))
|
||||||
|
* 修复运行流水线后会闪烁一下的bug ([dfc9362](https://github.com/certd/certd/commit/dfc9362084082ee535b898f23b2609c1d946a6fd))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 通知和定时器的删除按钮显示为红色更显眼 ([61ba83c](https://github.com/certd/certd/commit/61ba83c77546c3d505d081e19a3d68c127662bf1))
|
||||||
|
* 优化流水线列表页面、详情页面性能,精简返回数据 ([609ac9c](https://github.com/certd/certd/commit/609ac9c9a2dde605eb09834ae59693c1cb238765))
|
||||||
|
* OpenAPI支持autoApply参数 ([42f4d14](https://github.com/certd/certd/commit/42f4d1477dc791520a874aed56035abcbc8c433b))
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
**Note:** Version bump only for package @certd/ui-client
|
**Note:** Version bump only for package @certd/ui-client
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/ui-client",
|
"name": "@certd/ui-client",
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite --open",
|
"dev": "vite --open",
|
||||||
@@ -103,8 +103,8 @@
|
|||||||
"zod-defaults": "^0.1.3"
|
"zod-defaults": "^0.1.3"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@certd/lib-iframe": "^1.36.5",
|
"@certd/lib-iframe": "^1.36.14",
|
||||||
"@certd/pipeline": "^1.36.5",
|
"@certd/pipeline": "^1.36.14",
|
||||||
"@rollup/plugin-commonjs": "^25.0.7",
|
"@rollup/plugin-commonjs": "^25.0.7",
|
||||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||||
"@types/chai": "^4.3.12",
|
"@types/chai": "^4.3.12",
|
||||||
|
|||||||
@@ -0,0 +1,162 @@
|
|||||||
|
<template>
|
||||||
|
<div class="remote-auto-complete">
|
||||||
|
<div class="flex flex-row">
|
||||||
|
<a-auto-complete class="remote-auto-complete-input" :filter-option="filterOption" :options="optionsRef" :value="value" v-bind="attrs" @click="onClick" @update:value="emit('update:value', $event)">
|
||||||
|
</a-auto-complete>
|
||||||
|
<div class="ml-5">
|
||||||
|
<fs-button :loading="loading" title="刷新选项" icon="ion:refresh-outline" @click="refreshOptions"></fs-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="helper" :class="{ error: hasError }">
|
||||||
|
{{ message }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { ComponentPropsType, doRequest } from "/@/components/plugins/lib";
|
||||||
|
import { defineComponent, inject, ref, useAttrs, watch, Ref } from "vue";
|
||||||
|
import { PluginDefine } from "@certd/pipeline";
|
||||||
|
|
||||||
|
defineOptions({
|
||||||
|
name: "RemoteAutoComplete",
|
||||||
|
});
|
||||||
|
|
||||||
|
const props = defineProps<
|
||||||
|
{
|
||||||
|
watches: string[];
|
||||||
|
} & ComponentPropsType
|
||||||
|
>();
|
||||||
|
|
||||||
|
const emit = defineEmits<{
|
||||||
|
"update:value": any;
|
||||||
|
}>();
|
||||||
|
|
||||||
|
const attrs = useAttrs();
|
||||||
|
|
||||||
|
const getCurrentPluginDefine: any = inject("getCurrentPluginDefine", () => {
|
||||||
|
return {};
|
||||||
|
});
|
||||||
|
const getScope: any = inject("get:scope", () => {
|
||||||
|
return {};
|
||||||
|
});
|
||||||
|
const getPluginType: any = inject("get:plugin:type", () => {
|
||||||
|
return "plugin";
|
||||||
|
});
|
||||||
|
|
||||||
|
const optionsRef = ref([]);
|
||||||
|
const message = ref("");
|
||||||
|
const hasError = ref(false);
|
||||||
|
const loading = ref(false);
|
||||||
|
|
||||||
|
const getOptions = async () => {
|
||||||
|
if (loading.value) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!getCurrentPluginDefine) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
const define: PluginDefine = getCurrentPluginDefine()?.value;
|
||||||
|
if (!define) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const pluginType = getPluginType();
|
||||||
|
const { form } = getScope();
|
||||||
|
const input = (pluginType === "plugin" ? form?.input : form) || {};
|
||||||
|
|
||||||
|
for (let key in define.input) {
|
||||||
|
const inWatches = props.watches.includes(key);
|
||||||
|
const inputDefine = define.input[key];
|
||||||
|
if (inWatches && inputDefine.required) {
|
||||||
|
const value = input[key];
|
||||||
|
if (value == null || value === "") {
|
||||||
|
console.log("remote-select required", key);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
message.value = "";
|
||||||
|
hasError.value = false;
|
||||||
|
loading.value = true;
|
||||||
|
try {
|
||||||
|
const res = await doRequest(
|
||||||
|
{
|
||||||
|
type: pluginType,
|
||||||
|
typeName: form.type,
|
||||||
|
action: props.action,
|
||||||
|
input,
|
||||||
|
data: {},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
onError(err: any) {
|
||||||
|
hasError.value = true;
|
||||||
|
message.value = `获取选项出错:${err.message}`;
|
||||||
|
},
|
||||||
|
showErrorNotify: false,
|
||||||
|
}
|
||||||
|
);
|
||||||
|
const list = res?.list || res || [];
|
||||||
|
if (list.length > 0) {
|
||||||
|
message.value = "获取数据成功,请从下拉框中选择";
|
||||||
|
}
|
||||||
|
optionsRef.value = list;
|
||||||
|
|
||||||
|
return res;
|
||||||
|
} finally {
|
||||||
|
loading.value = false;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
const filterOption = (input: string, option: any) => {
|
||||||
|
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 || String(option.value).toLowerCase().indexOf(input.toLowerCase());
|
||||||
|
};
|
||||||
|
|
||||||
|
async function onClick() {
|
||||||
|
if (optionsRef.value?.length === 0) {
|
||||||
|
await refreshOptions();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
async function refreshOptions() {
|
||||||
|
await getOptions();
|
||||||
|
}
|
||||||
|
|
||||||
|
watch(
|
||||||
|
() => {
|
||||||
|
const pluginType = getPluginType();
|
||||||
|
const { form, key } = getScope();
|
||||||
|
const input = (pluginType === "plugin" ? form?.input : form) || {};
|
||||||
|
const watches = {};
|
||||||
|
for (const key of props.watches) {
|
||||||
|
//@ts-ignore
|
||||||
|
watches[key] = input[key];
|
||||||
|
}
|
||||||
|
return {
|
||||||
|
form: watches,
|
||||||
|
key,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
async (value, oldValue) => {
|
||||||
|
const { form } = value;
|
||||||
|
const oldForm: any = oldValue?.form;
|
||||||
|
let changed = oldForm == null || optionsRef.value.length == 0;
|
||||||
|
for (const key of props.watches) {
|
||||||
|
//@ts-ignore
|
||||||
|
if (oldForm && form[key] != oldForm[key]) {
|
||||||
|
changed = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (changed) {
|
||||||
|
await getOptions();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
immediate: true,
|
||||||
|
}
|
||||||
|
);
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="less"></style>
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
import SynologyIdDeviceGetter from "./synology/device-id-getter.vue";
|
import SynologyIdDeviceGetter from "./synology/device-id-getter.vue";
|
||||||
|
import RemoteAutoComplete from "./common/remote-auto-complete.vue";
|
||||||
import RemoteSelect from "./common/remote-select.vue";
|
import RemoteSelect from "./common/remote-select.vue";
|
||||||
import RemoteInput from "./common/remote-input.vue";
|
import RemoteInput from "./common/remote-input.vue";
|
||||||
import CertDomainsGetter from "./common/cert-domains-getter.vue";
|
import CertDomainsGetter from "./common/cert-domains-getter.vue";
|
||||||
@@ -21,6 +22,7 @@ export default {
|
|||||||
app.component("ApiTest", ApiTest);
|
app.component("ApiTest", ApiTest);
|
||||||
|
|
||||||
app.component("SynologyDeviceIdGetter", SynologyIdDeviceGetter);
|
app.component("SynologyDeviceIdGetter", SynologyIdDeviceGetter);
|
||||||
|
app.component("RemoteAutoComplete", RemoteAutoComplete);
|
||||||
app.component("RemoteSelect", RemoteSelect);
|
app.component("RemoteSelect", RemoteSelect);
|
||||||
app.component("RemoteInput", RemoteInput);
|
app.component("RemoteInput", RemoteInput);
|
||||||
app.component("CertDomainsGetter", CertDomainsGetter);
|
app.component("CertDomainsGetter", CertDomainsGetter);
|
||||||
|
|||||||
@@ -57,6 +57,7 @@ export default {
|
|||||||
passwordPlaceholder: "Please enter your password",
|
passwordPlaceholder: "Please enter your password",
|
||||||
mobilePlaceholder: "Please enter your mobile number",
|
mobilePlaceholder: "Please enter your mobile number",
|
||||||
loginButton: "Log In",
|
loginButton: "Log In",
|
||||||
|
forgotPassword: "Forgot password?",
|
||||||
forgotAdminPassword: "Forgot admin password?",
|
forgotAdminPassword: "Forgot admin password?",
|
||||||
registerLink: "Register",
|
registerLink: "Register",
|
||||||
|
|
||||||
|
|||||||
@@ -78,6 +78,7 @@ export default {
|
|||||||
runCount: "Run Count",
|
runCount: "Run Count",
|
||||||
expiringCerts: "Soon-to-Expire Certificates",
|
expiringCerts: "Soon-to-Expire Certificates",
|
||||||
supportedTasks: "Overview of Supported Deployment Tasks",
|
supportedTasks: "Overview of Supported Deployment Tasks",
|
||||||
|
changeLog: "Change Log",
|
||||||
},
|
},
|
||||||
steps: {
|
steps: {
|
||||||
createPipeline: "Create Certificate Pipeline",
|
createPipeline: "Create Certificate Pipeline",
|
||||||
@@ -449,7 +450,7 @@ export default {
|
|||||||
batchDeleteConfirm: "Are you sure to batch delete these {count} records?",
|
batchDeleteConfirm: "Are you sure to batch delete these {count} records?",
|
||||||
selectRecordFirst: "Please select records first",
|
selectRecordFirst: "Please select records first",
|
||||||
subdomainHosted: "Hosted Subdomain",
|
subdomainHosted: "Hosted Subdomain",
|
||||||
subdomainHelpText: "If you don't understand what subdomain hosting is, please refer to the documentation ",
|
subdomainHelpText: "If you don't understand what subdomain hosting is,Do not set it randomly, as it may result in the inability to apply for the certificate. please refer to the documentation ",
|
||||||
subdomainManagement: "Subdomain Management",
|
subdomainManagement: "Subdomain Management",
|
||||||
isDisabled: "Is Disabled",
|
isDisabled: "Is Disabled",
|
||||||
enabled: "Enabled",
|
enabled: "Enabled",
|
||||||
@@ -564,6 +565,7 @@ export default {
|
|||||||
dualStackNetworkHelper: "If IPv6 priority is selected, enable IPv6 in docker-compose.yaml",
|
dualStackNetworkHelper: "If IPv6 priority is selected, enable IPv6 in docker-compose.yaml",
|
||||||
enableCommonCnameService: "Enable Public CNAME Service",
|
enableCommonCnameService: "Enable Public CNAME Service",
|
||||||
commonCnameHelper: "Allow use of public CNAME service. If disabled and no <router-link to='/sys/cname/provider'>custom CNAME service</router-link> is set, CNAME proxy certificate application will not work.",
|
commonCnameHelper: "Allow use of public CNAME service. If disabled and no <router-link to='/sys/cname/provider'>custom CNAME service</router-link> is set, CNAME proxy certificate application will not work.",
|
||||||
|
enableCommonSelfServicePasswordRetrieval: "Enable self-service password recovery",
|
||||||
saveButton: "Save",
|
saveButton: "Save",
|
||||||
stopSuccess: "Stopped successfully",
|
stopSuccess: "Stopped successfully",
|
||||||
google: "Google",
|
google: "Google",
|
||||||
|
|||||||
@@ -57,6 +57,7 @@ export default {
|
|||||||
passwordPlaceholder: "请输入密码",
|
passwordPlaceholder: "请输入密码",
|
||||||
mobilePlaceholder: "请输入手机号",
|
mobilePlaceholder: "请输入手机号",
|
||||||
loginButton: "登录",
|
loginButton: "登录",
|
||||||
|
forgotPassword: "忘记密码?",
|
||||||
forgotAdminPassword: "忘记管理员密码?",
|
forgotAdminPassword: "忘记管理员密码?",
|
||||||
registerLink: "注册",
|
registerLink: "注册",
|
||||||
|
|
||||||
|
|||||||
@@ -84,6 +84,7 @@ export default {
|
|||||||
runCount: "运行次数",
|
runCount: "运行次数",
|
||||||
expiringCerts: "最快到期证书",
|
expiringCerts: "最快到期证书",
|
||||||
supportedTasks: "已支持的部署任务总览",
|
supportedTasks: "已支持的部署任务总览",
|
||||||
|
changeLog: "更新日志",
|
||||||
},
|
},
|
||||||
steps: {
|
steps: {
|
||||||
createPipeline: "创建证书流水线",
|
createPipeline: "创建证书流水线",
|
||||||
@@ -415,7 +416,7 @@ export default {
|
|||||||
is_present_no: "否",
|
is_present_no: "否",
|
||||||
basicInfo: "基础信息",
|
basicInfo: "基础信息",
|
||||||
titlea: "名称",
|
titlea: "名称",
|
||||||
disabled: "是否禁用",
|
disabled: "禁用",
|
||||||
ordera: "排序",
|
ordera: "排序",
|
||||||
supportBuy: "支持购买",
|
supportBuy: "支持购买",
|
||||||
intro: "介绍",
|
intro: "介绍",
|
||||||
@@ -455,7 +456,7 @@ export default {
|
|||||||
batchDeleteConfirm: "确定要批量删除这{count}条记录吗",
|
batchDeleteConfirm: "确定要批量删除这{count}条记录吗",
|
||||||
selectRecordFirst: "请先勾选记录",
|
selectRecordFirst: "请先勾选记录",
|
||||||
subdomainHosted: "托管的子域名",
|
subdomainHosted: "托管的子域名",
|
||||||
subdomainHelpText: "如果您不理解什么是子域托管,可以参考文档",
|
subdomainHelpText: "如果您不理解什么是子域托管,请不要随意设置,可能导致证书无法申请,可以参考文档",
|
||||||
subdomainManagement: "子域管理",
|
subdomainManagement: "子域管理",
|
||||||
isDisabled: "是否禁用",
|
isDisabled: "是否禁用",
|
||||||
enabled: "启用",
|
enabled: "启用",
|
||||||
@@ -570,6 +571,7 @@ export default {
|
|||||||
dualStackNetworkHelper: "如果选择IPv6优先,需要在docker-compose.yaml中启用ipv6",
|
dualStackNetworkHelper: "如果选择IPv6优先,需要在docker-compose.yaml中启用ipv6",
|
||||||
enableCommonCnameService: "启用公共CNAME服务",
|
enableCommonCnameService: "启用公共CNAME服务",
|
||||||
commonCnameHelper: "是否可以使用公共CNAME服务,如果禁用,且没有设置<router-link to='/sys/cname/provider'>自定义CNAME服务</router-link>,则无法使用CNAME代理方式申请证书",
|
commonCnameHelper: "是否可以使用公共CNAME服务,如果禁用,且没有设置<router-link to='/sys/cname/provider'>自定义CNAME服务</router-link>,则无法使用CNAME代理方式申请证书",
|
||||||
|
enableCommonSelfServicePasswordRetrieval: "启用自助找回密码",
|
||||||
saveButton: "保存",
|
saveButton: "保存",
|
||||||
stopSuccess: "停止成功",
|
stopSuccess: "停止成功",
|
||||||
google: "Google",
|
google: "Google",
|
||||||
|
|||||||
@@ -24,6 +24,14 @@ export const outsideResource = [
|
|||||||
path: "/register",
|
path: "/register",
|
||||||
component: "/framework/register/index.vue",
|
component: "/framework/register/index.vue",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
meta: {
|
||||||
|
title: "找回密码",
|
||||||
|
},
|
||||||
|
name: "forgotPassword",
|
||||||
|
path: "/forgotPassword",
|
||||||
|
component: "/framework/forgot-password/index.vue",
|
||||||
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
...errorPage,
|
...errorPage,
|
||||||
|
|||||||
@@ -36,6 +36,7 @@ export type SysPublicSetting = {
|
|||||||
emailRegisterEnabled?: boolean;
|
emailRegisterEnabled?: boolean;
|
||||||
passwordLoginEnabled?: boolean;
|
passwordLoginEnabled?: boolean;
|
||||||
smsLoginEnabled?: boolean;
|
smsLoginEnabled?: boolean;
|
||||||
|
selfServicePasswordRetrievalEnabled?: boolean;
|
||||||
|
|
||||||
limitUserPipelineCount?: number;
|
limitUserPipelineCount?: number;
|
||||||
managerOtherUserPipeline?: boolean;
|
managerOtherUserPipeline?: boolean;
|
||||||
|
|||||||
@@ -46,6 +46,10 @@ export interface SettingState {
|
|||||||
price3: number;
|
price3: number;
|
||||||
tooltip?: string;
|
tooltip?: string;
|
||||||
};
|
};
|
||||||
|
app?: {
|
||||||
|
minVersion?: string;
|
||||||
|
minVersionTip?: string;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -107,6 +111,10 @@ export const useSettingStore = defineStore({
|
|||||||
price: 399,
|
price: 399,
|
||||||
price3: 899,
|
price3: 899,
|
||||||
},
|
},
|
||||||
|
app: {
|
||||||
|
minVersion: "",
|
||||||
|
minVersionTip: "",
|
||||||
|
},
|
||||||
},
|
},
|
||||||
}),
|
}),
|
||||||
getters: {
|
getters: {
|
||||||
|
|||||||
@@ -20,6 +20,17 @@ export interface SmsLoginReq {
|
|||||||
randomStr: string;
|
randomStr: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export interface ForgotPasswordReq {
|
||||||
|
forgotPasswordType: string;
|
||||||
|
input: string;
|
||||||
|
randomStr: string;
|
||||||
|
imgCode: string;
|
||||||
|
validateCode: string;
|
||||||
|
|
||||||
|
password: string;
|
||||||
|
confirmPassword: string;
|
||||||
|
}
|
||||||
|
|
||||||
export interface UserInfoRes {
|
export interface UserInfoRes {
|
||||||
id: string | number;
|
id: string | number;
|
||||||
username: string;
|
username: string;
|
||||||
@@ -43,6 +54,13 @@ export async function register(user: RegisterReq): Promise<UserInfoRes> {
|
|||||||
data: user,
|
data: user,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
export async function forgotPassword(data: ForgotPasswordReq): Promise<any> {
|
||||||
|
return await request({
|
||||||
|
url: "/forgotPassword",
|
||||||
|
method: "post",
|
||||||
|
data: data,
|
||||||
|
});
|
||||||
|
}
|
||||||
export async function logout() {
|
export async function logout() {
|
||||||
return await request({
|
return await request({
|
||||||
url: "/logout",
|
url: "/logout",
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import router from "../../router";
|
|||||||
import { LocalStorage } from "/src/utils/util.storage";
|
import { LocalStorage } from "/src/utils/util.storage";
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import * as UserApi from "./api.user";
|
import * as UserApi from "./api.user";
|
||||||
import { RegisterReq, SmsLoginReq } from "./api.user";
|
import { ForgotPasswordReq, RegisterReq, SmsLoginReq } from "./api.user";
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { LoginReq, UserInfoRes } from "/@/store/user/api.user";
|
import { LoginReq, UserInfoRes } from "/@/store/user/api.user";
|
||||||
import { message, Modal, notification } from "ant-design-vue";
|
import { message, Modal, notification } from "ant-design-vue";
|
||||||
@@ -67,6 +67,13 @@ export const useUserStore = defineStore({
|
|||||||
});
|
});
|
||||||
await router.replace("/login");
|
await router.replace("/login");
|
||||||
},
|
},
|
||||||
|
async forgotPassword(params: ForgotPasswordReq): Promise<any> {
|
||||||
|
await UserApi.forgotPassword(params);
|
||||||
|
notification.success({
|
||||||
|
message: "密码已重置,请登录",
|
||||||
|
});
|
||||||
|
await router.replace("/login");
|
||||||
|
},
|
||||||
/**
|
/**
|
||||||
* @description: login
|
* @description: login
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -488,7 +488,7 @@ const idMainContent = ELEMENT_ID_MAIN_CONTENT;
|
|||||||
</template>
|
</template>
|
||||||
</LayoutContent>
|
</LayoutContent>
|
||||||
|
|
||||||
<LayoutFooter v-if="footerEnable" class="hidden md:block" :fixed="footerFixed" :height="footerHeight" :show="!isFullContent" :width="footerWidth" :z-index="zIndex + 2">
|
<LayoutFooter v-if="footerEnable" class="hidden md:block" :fixed="footerFixed" :height="footerHeight" :show="!isFullContent" :width="footerWidth" :z-index="zIndex">
|
||||||
<slot name="footer"></slot>
|
<slot name="footer"></slot>
|
||||||
</LayoutFooter>
|
</LayoutFooter>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -112,7 +112,8 @@ function menuIcon(menu: MenuRecordRaw) {
|
|||||||
|
|
||||||
.vben-normal-menu__name,
|
.vben-normal-menu__name,
|
||||||
.vben-normal-menu__icon {
|
.vben-normal-menu__icon {
|
||||||
@apply text-primary-foreground font-semibold;
|
//@apply text-primary-foreground font-semibold;
|
||||||
|
@apply font-semibold;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ export default function ({ crudExpose, context }: CreateCrudOptionsProps): Creat
|
|||||||
show: false,
|
show: false,
|
||||||
},
|
},
|
||||||
search: {
|
search: {
|
||||||
show: false,
|
show: true,
|
||||||
},
|
},
|
||||||
form: {
|
form: {
|
||||||
wrapper: {
|
wrapper: {
|
||||||
|
|||||||
@@ -46,6 +46,20 @@ export default function ({ crudExpose, context }: CreateCrudOptionsProps): Creat
|
|||||||
|
|
||||||
const { openSiteIpMonitorDialog } = useSiteIpMonitor();
|
const { openSiteIpMonitorDialog } = useSiteIpMonitor();
|
||||||
const { openSiteImportDialog } = useSiteImport();
|
const { openSiteImportDialog } = useSiteImport();
|
||||||
|
|
||||||
|
function checkAll() {
|
||||||
|
Modal.confirm({
|
||||||
|
title: t("certd.monitor.confirmTitle"), // "确认"
|
||||||
|
content: t("certd.monitor.confirmContent"), // "确认触发检查全部站点证书吗?"
|
||||||
|
onOk: async () => {
|
||||||
|
await siteInfoApi.CheckAll();
|
||||||
|
notification.success({
|
||||||
|
message: t("certd.monitor.checkSubmitted"), // "检查任务已提交"
|
||||||
|
description: t("certd.monitor.pleaseRefresh"), // "请稍后刷新页面查看结果"
|
||||||
|
});
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
return {
|
return {
|
||||||
id: "siteMonitorCrud",
|
id: "siteMonitorCrud",
|
||||||
crudOptions: {
|
crudOptions: {
|
||||||
@@ -114,6 +128,14 @@ export default function ({ crudExpose, context }: CreateCrudOptionsProps): Creat
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
checkAll: {
|
||||||
|
show: true,
|
||||||
|
text: t("certd.monitor.checkAll"),
|
||||||
|
type: "primary",
|
||||||
|
click() {
|
||||||
|
checkAll();
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
rowHandle: {
|
rowHandle: {
|
||||||
|
|||||||
@@ -14,9 +14,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="more">
|
|
||||||
<a-button type="primary" @click="checkAll">{{ t("certd.monitor.checkAll") }}</a-button>
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
<fs-crud ref="crudRef" v-bind="crudBinding"> </fs-crud>
|
<fs-crud ref="crudRef" v-bind="crudBinding"> </fs-crud>
|
||||||
</fs-page>
|
</fs-page>
|
||||||
@@ -35,19 +32,6 @@ defineOptions({
|
|||||||
name: "SiteCertMonitor",
|
name: "SiteCertMonitor",
|
||||||
});
|
});
|
||||||
const { crudBinding, crudRef, crudExpose } = useFs({ createCrudOptions, context: {} });
|
const { crudBinding, crudRef, crudExpose } = useFs({ createCrudOptions, context: {} });
|
||||||
function checkAll() {
|
|
||||||
Modal.confirm({
|
|
||||||
title: t("certd.monitor.confirmTitle"), // "确认"
|
|
||||||
content: t("certd.monitor.confirmContent"), // "确认触发检查全部站点证书吗?"
|
|
||||||
onOk: async () => {
|
|
||||||
await siteInfoApi.CheckAll();
|
|
||||||
notification.success({
|
|
||||||
message: t("certd.monitor.checkSubmitted"), // "检查任务已提交"
|
|
||||||
description: t("certd.monitor.pleaseRefresh"), // "请稍后刷新页面查看结果"
|
|
||||||
});
|
|
||||||
},
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 页面打开后获取列表数据
|
// 页面打开后获取列表数据
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
|||||||
@@ -125,6 +125,7 @@ export function useCertPipelineCreator() {
|
|||||||
const pluginStore = usePluginStore();
|
const pluginStore = usePluginStore();
|
||||||
const randomHour = Math.floor(Math.random() * 6);
|
const randomHour = Math.floor(Math.random() * 6);
|
||||||
const randomMin = Math.floor(Math.random() * 60);
|
const randomMin = Math.floor(Math.random() * 60);
|
||||||
|
const randomCron = `0 ${randomMin} ${randomHour} * * *`;
|
||||||
|
|
||||||
const groupDictRef = dict({
|
const groupDictRef = dict({
|
||||||
url: "/pi/pipeline/group/all",
|
url: "/pi/pipeline/group/all",
|
||||||
@@ -193,7 +194,7 @@ export function useCertPipelineCreator() {
|
|||||||
title: t("certd.pipelineForm.triggerCronTitle"),
|
title: t("certd.pipelineForm.triggerCronTitle"),
|
||||||
type: "text",
|
type: "text",
|
||||||
form: {
|
form: {
|
||||||
value: `0 ${randomMin} ${randomHour} * * *`,
|
value: randomCron,
|
||||||
component: {
|
component: {
|
||||||
name: "cron-editor",
|
name: "cron-editor",
|
||||||
vModel: "modelValue",
|
vModel: "modelValue",
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ import { useCertUpload } from "/@/views/certd/pipeline/cert-upload/use";
|
|||||||
import GroupSelector from "/@/views/certd/pipeline/group/group-selector.vue";
|
import GroupSelector from "/@/views/certd/pipeline/group/group-selector.vue";
|
||||||
import { useCertViewer } from "/@/views/certd/pipeline/use";
|
import { useCertViewer } from "/@/views/certd/pipeline/use";
|
||||||
import { useI18n } from "/src/locales";
|
import { useI18n } from "/src/locales";
|
||||||
|
import { GetDetail, GetObj } from "./api";
|
||||||
|
|
||||||
export default function ({ crudExpose, context: { groupDictRef, selectedRowKeys } }: CreateCrudOptionsProps): CreateCrudOptionsRet {
|
export default function ({ crudExpose, context: { groupDictRef, selectedRowKeys } }: CreateCrudOptionsProps): CreateCrudOptionsRet {
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
@@ -200,7 +201,9 @@ export default function ({ crudExpose, context: { groupDictRef, selectedRowKeys
|
|||||||
const { ui } = useUi();
|
const { ui } = useUi();
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
let row = context[ui.tableColumn.row];
|
let row = context[ui.tableColumn.row];
|
||||||
row = cloneDeep(row);
|
const info = await GetDetail(row.id);
|
||||||
|
row = info.pipeline;
|
||||||
|
row.content = JSON.parse(row.content);
|
||||||
row.title = row.title + "_copy";
|
row.title = row.title + "_copy";
|
||||||
await crudExpose.openCopy({
|
await crudExpose.openCopy({
|
||||||
row: row,
|
row: row,
|
||||||
@@ -335,7 +338,7 @@ export default function ({ crudExpose, context: { groupDictRef, selectedRowKeys
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
_triggerCount: {
|
triggerCount: {
|
||||||
title: t("certd.fields.scheduledTaskCount"),
|
title: t("certd.fields.scheduledTaskCount"),
|
||||||
type: "number",
|
type: "number",
|
||||||
column: {
|
column: {
|
||||||
@@ -346,7 +349,7 @@ export default function ({ crudExpose, context: { groupDictRef, selectedRowKeys
|
|||||||
show: false,
|
show: false,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
_stepCount: {
|
stepCount: {
|
||||||
title: t("certd.fields.deployTaskCount"),
|
title: t("certd.fields.deployTaskCount"),
|
||||||
type: "number",
|
type: "number",
|
||||||
form: { show: false },
|
form: { show: false },
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<fs-icon v-bind="status" :color="status.iconColor || status.color" />
|
<fs-icon v-bind="status" :color="status.iconColor || status.color" />
|
||||||
</template>
|
</template>
|
||||||
<p>
|
<p>
|
||||||
<fs-date-format :model-value="runnable.status?.startTime"></fs-date-format>
|
<fs-date-format :model-value="runnable.createTime"></fs-date-format>
|
||||||
<a-tag class="ml-5" :color="status.color" :closable="status.value === 'start'" @close="cancelTask">
|
<a-tag class="ml-5" :color="status.color" :closable="status.value === 'start'" @close="cancelTask">
|
||||||
{{ status.label }}
|
{{ status.label }}
|
||||||
</a-tag>
|
</a-tag>
|
||||||
@@ -46,7 +46,7 @@ export default defineComponent({
|
|||||||
emits: ["view", "cancel"],
|
emits: ["view", "cancel"],
|
||||||
setup(props: any, ctx: any) {
|
setup(props: any, ctx: any) {
|
||||||
const status = computed(() => {
|
const status = computed(() => {
|
||||||
return statusUtil.get(props.runnable?.status?.result);
|
return statusUtil.get(props.runnable?.status);
|
||||||
});
|
});
|
||||||
|
|
||||||
function view() {
|
function view() {
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<div>
|
<div>
|
||||||
{{ t("certd.edit_notification") }}
|
{{ t("certd.edit_notification") }}
|
||||||
<a-button v-if="mode === 'edit'" @click="notificationDelete()">
|
<a-button v-if="mode === 'edit'" danger @click="notificationDelete()">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<DeleteOutlined />
|
<DeleteOutlined />
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -26,7 +26,8 @@
|
|||||||
</template>
|
</template>
|
||||||
<div class="flex-col h-100 w-100 overflow-hidden">
|
<div class="flex-col h-100 w-100 overflow-hidden">
|
||||||
<a-tabs v-model:active-key="pluginGroupActive" tab-position="left" class="flex-1 overflow-hidden">
|
<a-tabs v-model:active-key="pluginGroupActive" tab-position="left" class="flex-1 overflow-hidden">
|
||||||
<a-tab-pane v-for="group of computedPluginGroups" :key="group.key" class="scroll-y">
|
<template v-for="group of computedPluginGroups" :key="group.key">
|
||||||
|
<a-tab-pane v-if="(group.key === 'admin' && userStore.isAdmin) || group.key !== 'admin'" :key="group.key" class="scroll-y">
|
||||||
<template #tab>
|
<template #tab>
|
||||||
<div class="cd-step-form-tab-label">
|
<div class="cd-step-form-tab-label">
|
||||||
<fs-icon :icon="group.icon" class="mr-2" />
|
<fs-icon :icon="group.icon" class="mr-2" />
|
||||||
@@ -63,6 +64,7 @@
|
|||||||
</a-col>
|
</a-col>
|
||||||
</a-row>
|
</a-row>
|
||||||
</a-tab-pane>
|
</a-tab-pane>
|
||||||
|
</template>
|
||||||
</a-tabs>
|
</a-tabs>
|
||||||
</div>
|
</div>
|
||||||
<template #footer>
|
<template #footer>
|
||||||
@@ -124,6 +126,7 @@ import { useReference } from "/@/use/use-refrence";
|
|||||||
import { useSettingStore } from "/@/store/settings";
|
import { useSettingStore } from "/@/store/settings";
|
||||||
import { mitter } from "/@/utils/util.mitt";
|
import { mitter } from "/@/utils/util.mitt";
|
||||||
import { utils } from "/@/utils";
|
import { utils } from "/@/utils";
|
||||||
|
import { useUserStore } from "/@/store/user";
|
||||||
|
|
||||||
defineOptions({
|
defineOptions({
|
||||||
name: "PiStepForm",
|
name: "PiStepForm",
|
||||||
@@ -138,7 +141,7 @@ const props = defineProps({
|
|||||||
const emit = defineEmits(["update"]);
|
const emit = defineEmits(["update"]);
|
||||||
|
|
||||||
const pluginStore = usePluginStore();
|
const pluginStore = usePluginStore();
|
||||||
|
const userStore = useUserStore();
|
||||||
function transformDesc(desc: string = "") {
|
function transformDesc(desc: string = "") {
|
||||||
return utils.transformLink(desc);
|
return utils.transformLink(desc);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<div>
|
<div>
|
||||||
编辑任务
|
编辑任务
|
||||||
<a-button v-if="editMode" @click="taskDelete()">
|
<a-button v-if="editMode" danger @click="taskDelete()">
|
||||||
<template #icon><DeleteOutlined /></template>
|
<template #icon><DeleteOutlined /></template>
|
||||||
</a-button>
|
</a-button>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<div>
|
<div>
|
||||||
{{ t("certd.editTrigger") }}
|
{{ t("certd.editTrigger") }}
|
||||||
<a-button v-if="mode === 'edit'" @click="triggerDelete()">
|
<a-button v-if="mode === 'edit'" danger @click="triggerDelete()">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<DeleteOutlined />
|
<DeleteOutlined />
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -258,7 +258,7 @@
|
|||||||
<a-timeline class="mt-10">
|
<a-timeline class="mt-10">
|
||||||
<template v-for="item of histories" :key="item.id">
|
<template v-for="item of histories" :key="item.id">
|
||||||
<pi-history-timeline-item
|
<pi-history-timeline-item
|
||||||
:runnable="item.pipeline"
|
:runnable="item"
|
||||||
:history-id="item.id"
|
:history-id="item.id"
|
||||||
:is-current="currentHistory?.id === item.id"
|
:is-current="currentHistory?.id === item.id"
|
||||||
:edit-mode="editMode"
|
:edit-mode="editMode"
|
||||||
@@ -280,7 +280,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { defineComponent, onMounted, onUnmounted, provide, Ref, ref, watch, computed } from "vue";
|
import { computed, defineComponent, onMounted, onUnmounted, provide, ref, Ref, watch } from "vue";
|
||||||
import { useRouter } from "vue-router";
|
import { useRouter } from "vue-router";
|
||||||
import PiTaskForm from "./component/task-form/index.vue";
|
import PiTaskForm from "./component/task-form/index.vue";
|
||||||
import PiTriggerForm from "./component/trigger-form/index.vue";
|
import PiTriggerForm from "./component/trigger-form/index.vue";
|
||||||
@@ -288,7 +288,7 @@ import PiNotificationForm from "./component/notification-form/index.vue";
|
|||||||
import PiTaskView from "./component/task-view/index.vue";
|
import PiTaskView from "./component/task-view/index.vue";
|
||||||
import PiStatusShow from "./component/status-show.vue";
|
import PiStatusShow from "./component/status-show.vue";
|
||||||
import VDraggable from "vuedraggable";
|
import VDraggable from "vuedraggable";
|
||||||
import * as _ from "lodash-es";
|
import { cloneDeep, merge, remove } from "lodash-es";
|
||||||
import { message, Modal, notification } from "ant-design-vue";
|
import { message, Modal, notification } from "ant-design-vue";
|
||||||
import { nanoid } from "nanoid";
|
import { nanoid } from "nanoid";
|
||||||
import { PipelineDetail, PipelineOptions, RunHistory } from "./type";
|
import { PipelineDetail, PipelineOptions, RunHistory } from "./type";
|
||||||
@@ -298,10 +298,11 @@ import { FsIcon } from "@fast-crud/fast-crud";
|
|||||||
import { useSettingStore } from "/@/store/settings";
|
import { useSettingStore } from "/@/store/settings";
|
||||||
import { useUserStore } from "/@/store/user";
|
import { useUserStore } from "/@/store/user";
|
||||||
import TaskShortcuts from "./component/shortcut/task-shortcuts.vue";
|
import TaskShortcuts from "./component/shortcut/task-shortcuts.vue";
|
||||||
import { eachSteps, findStep } from "../utils";
|
import { eachSteps, findStep, eachStages } from "../utils";
|
||||||
import { PluginGroups, usePluginStore } from "/@/store/plugin";
|
import { usePluginStore } from "/@/store/plugin";
|
||||||
import { getCronNextTimes } from "/@/components/cron-editor/utils";
|
import { getCronNextTimes } from "/@/components/cron-editor/utils";
|
||||||
import { useCertViewer } from "/@/views/certd/pipeline/use";
|
import { useCertViewer } from "/@/views/certd/pipeline/use";
|
||||||
|
import { useI18n } from "/@/locales";
|
||||||
|
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
name: "PipelineEdit",
|
name: "PipelineEdit",
|
||||||
@@ -339,6 +340,7 @@ export default defineComponent({
|
|||||||
},
|
},
|
||||||
emits: ["update:modelValue", "update:editMode"],
|
emits: ["update:modelValue", "update:editMode"],
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
|
const { t } = useI18n();
|
||||||
const currentPipeline: Ref<any> = ref({});
|
const currentPipeline: Ref<any> = ref({});
|
||||||
const pipeline: Ref<any> = ref({});
|
const pipeline: Ref<any> = ref({});
|
||||||
|
|
||||||
@@ -371,18 +373,23 @@ export default defineComponent({
|
|||||||
const loadCurrentHistoryDetail = async () => {
|
const loadCurrentHistoryDetail = async () => {
|
||||||
const detail: RunHistory = await props.options?.getHistoryDetail({ historyId: currentHistory.value.id });
|
const detail: RunHistory = await props.options?.getHistoryDetail({ historyId: currentHistory.value.id });
|
||||||
currentHistory.value.logs = detail.logs;
|
currentHistory.value.logs = detail.logs;
|
||||||
_.merge(currentHistory.value.pipeline, detail.pipeline);
|
currentHistory.value.pipeline = detail.pipeline;
|
||||||
|
currentHistory.value.status = detail.pipeline.status.result;
|
||||||
};
|
};
|
||||||
const changeCurrentHistory = async (history?: RunHistory) => {
|
const changeCurrentHistory = async (history?: RunHistory) => {
|
||||||
if (!history) {
|
if (!history) {
|
||||||
//取消历史记录查看模式
|
//取消历史记录查看模式
|
||||||
currentHistory.value = null;
|
currentHistory.value = null;
|
||||||
pipeline.value = currentPipeline.value;
|
pipeline.value = cloneDeep(currentPipeline.value);
|
||||||
|
eachStages(pipeline.value.stages, item => {
|
||||||
|
item.status = null;
|
||||||
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
currentHistory.value = history;
|
currentHistory.value = history;
|
||||||
pipeline.value = history.pipeline;
|
|
||||||
await loadCurrentHistoryDetail();
|
await loadCurrentHistoryDetail();
|
||||||
|
pipeline.value = currentHistory.value.pipeline;
|
||||||
|
currentPipeline.value = currentHistory.value.pipeline;
|
||||||
};
|
};
|
||||||
|
|
||||||
async function loadHistoryList(reload = false) {
|
async function loadHistoryList(reload = false) {
|
||||||
@@ -413,7 +420,8 @@ export default defineComponent({
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (historyList[0].pipeline?.version === pipeline.value.version) {
|
//@ts-ignore
|
||||||
|
if (historyList[0]?.version === pipeline.value.version) {
|
||||||
await changeCurrentHistory(historyList[0]);
|
await changeCurrentHistory(historyList[0]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -435,8 +443,13 @@ export default defineComponent({
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (currentHistory.value != null) {
|
if (currentHistory.value != null) {
|
||||||
if (currentHistory.value.pipeline?.status?.status === "start") {
|
if (currentHistory.value.status === "start") {
|
||||||
await loadCurrentHistoryDetail();
|
await loadCurrentHistoryDetail();
|
||||||
|
pipeline.value = currentHistory.value.pipeline;
|
||||||
|
// if (currentHistory.value.pipeline?.status?.status !== "start") {
|
||||||
|
// 不传true好像不会刷新
|
||||||
|
// await loadHistoryList(true);
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
@@ -477,7 +490,7 @@ export default defineComponent({
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const detail: PipelineDetail = await props.options.getPipelineDetail({ pipelineId: value });
|
const detail: PipelineDetail = await props.options.getPipelineDetail({ pipelineId: value });
|
||||||
currentPipeline.value = _.merge(
|
currentPipeline.value = merge(
|
||||||
{
|
{
|
||||||
title: "新管道流程",
|
title: "新管道流程",
|
||||||
stages: [],
|
stages: [],
|
||||||
@@ -540,7 +553,7 @@ export default defineComponent({
|
|||||||
};
|
};
|
||||||
|
|
||||||
const taskCopy = (stage: any, stageIndex: number, task: any) => {
|
const taskCopy = (stage: any, stageIndex: number, task: any) => {
|
||||||
task = _.cloneDeep(task);
|
task = cloneDeep(task);
|
||||||
task.id = nanoid();
|
task.id = nanoid();
|
||||||
task.title = task.title + "_copy";
|
task.title = task.title + "_copy";
|
||||||
for (const step of task.steps) {
|
for (const step of task.steps) {
|
||||||
@@ -560,7 +573,7 @@ export default defineComponent({
|
|||||||
if (type === "delete") {
|
if (type === "delete") {
|
||||||
stage.tasks.splice(taskIndex, 1);
|
stage.tasks.splice(taskIndex, 1);
|
||||||
if (stage.tasks.length === 0) {
|
if (stage.tasks.length === 0) {
|
||||||
_.remove(pipeline.value.stages, (item: Runnable) => {
|
remove(pipeline.value.stages, (item: Runnable) => {
|
||||||
return item.id === stage.id;
|
return item.id === stage.id;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -666,9 +679,19 @@ export default defineComponent({
|
|||||||
notificationFormRef.value.notificationView(notification, (type: string, value: any) => {});
|
notificationFormRef.value.notificationView(notification, (type: string, value: any) => {});
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
const notificationDelete = (notification: any, index: any) => {
|
||||||
|
Modal.confirm({
|
||||||
|
title: t("certd.confirm"),
|
||||||
|
content: t("certd.confirm_delete_trigger"),
|
||||||
|
async onOk() {
|
||||||
|
pipeline.value.notifications.splice(index, 1);
|
||||||
|
},
|
||||||
|
});
|
||||||
|
};
|
||||||
return {
|
return {
|
||||||
notificationAdd,
|
notificationAdd,
|
||||||
notificationEdit,
|
notificationEdit,
|
||||||
|
notificationDelete,
|
||||||
notificationFormRef,
|
notificationFormRef,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -788,7 +811,7 @@ export default defineComponent({
|
|||||||
currentPipeline.value = pipeline.value;
|
currentPipeline.value = pipeline.value;
|
||||||
|
|
||||||
//移除空阶段
|
//移除空阶段
|
||||||
_.remove(pipeline.value.stages, (item: Stage) => {
|
remove(pipeline.value.stages, (item: Stage) => {
|
||||||
return item.tasks.length === 0;
|
return item.tasks.length === 0;
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -802,12 +825,12 @@ export default defineComponent({
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
const edit = () => {
|
const edit = () => {
|
||||||
pipeline.value = _.cloneDeep(currentPipeline.value);
|
pipeline.value = cloneDeep(currentPipeline.value);
|
||||||
currentHistory.value = null;
|
currentHistory.value = null;
|
||||||
toggleEditMode(true);
|
toggleEditMode(true);
|
||||||
};
|
};
|
||||||
const cancel = () => {
|
const cancel = () => {
|
||||||
pipeline.value = currentPipeline.value;
|
pipeline.value = cloneDeep(currentPipeline.value);
|
||||||
toggleEditMode(false);
|
toggleEditMode(false);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,12 @@
|
|||||||
<template #header>
|
<template #header>
|
||||||
<div class="title">
|
<div class="title">
|
||||||
{{ t("certd.subdomainHosting") }}
|
{{ t("certd.subdomainHosting") }}
|
||||||
<span class="sub">{{ t("certd.subdomainHostingHint") }}</span>
|
<span class="sub">
|
||||||
|
{{ t("certd.subdomainHostingHint") }}; {{ t("certd.subdomainHelpText") }}
|
||||||
|
<a href="https://help.aliyun.com/zh/dns/subdomain-management" target="_blank">
|
||||||
|
{{ t("certd.subdomainManagement") }}
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<fs-crud ref="crudRef" v-bind="crudBinding">
|
<fs-crud ref="crudRef" v-bind="crudBinding">
|
||||||
|
|||||||
@@ -0,0 +1,179 @@
|
|||||||
|
<template>
|
||||||
|
<div class="main forgot-password-page">
|
||||||
|
<a-form
|
||||||
|
ref="formRef"
|
||||||
|
class="user-layout-forgot-password"
|
||||||
|
name="custom-validation"
|
||||||
|
:model="formState"
|
||||||
|
:rules="rules"
|
||||||
|
v-bind="layout"
|
||||||
|
:label-col="{ span: 6 }"
|
||||||
|
@finish="handleFinish"
|
||||||
|
@finish-failed="handleFinishFailed"
|
||||||
|
>
|
||||||
|
<a-tabs v-model:active-key="forgotPasswordType" :destroyInactiveTabPane="true">
|
||||||
|
<a-tab-pane key="email" tab="邮箱找回">
|
||||||
|
<a-form-item has-feedback name="input" label="邮箱">
|
||||||
|
<a-input v-model:value="formState.input" placeholder="邮箱" size="large" autocomplete="off">
|
||||||
|
<template #prefix>
|
||||||
|
<fs-icon icon="ion:mail-outline"></fs-icon>
|
||||||
|
</template>
|
||||||
|
</a-input>
|
||||||
|
</a-form-item>
|
||||||
|
<a-form-item has-feedback name="validateCode" label="邮件验证码">
|
||||||
|
<email-code
|
||||||
|
v-model:value="formState.validateCode"
|
||||||
|
:img-code="formState.imgCode"
|
||||||
|
:email="formState.input"
|
||||||
|
:random-str="formState.randomStr"
|
||||||
|
verification-type="forgotPassword"
|
||||||
|
/>
|
||||||
|
</a-form-item>
|
||||||
|
</a-tab-pane>
|
||||||
|
<a-tab-pane key="mobile" tab="手机号找回">
|
||||||
|
<a-form-item required has-feedback name="input" label="手机号">
|
||||||
|
<a-input v-model:value="formState.input" placeholder="手机号" autocomplete="off">
|
||||||
|
<template #prefix>
|
||||||
|
<fs-icon icon="ion:phone-portrait-outline"></fs-icon>
|
||||||
|
</template>
|
||||||
|
</a-input>
|
||||||
|
</a-form-item>
|
||||||
|
<a-form-item name="validateCode" label="手机验证码">
|
||||||
|
<sms-code
|
||||||
|
v-model:value="formState.validateCode"
|
||||||
|
:img-code="formState.imgCode"
|
||||||
|
:mobile="formState.input"
|
||||||
|
:phone-code="formState.phoneCode"
|
||||||
|
:random-str="formState.randomStr"
|
||||||
|
verification-type="forgotPassword"
|
||||||
|
/>
|
||||||
|
</a-form-item>
|
||||||
|
</a-tab-pane>
|
||||||
|
</a-tabs>
|
||||||
|
|
||||||
|
<a-form-item has-feedback name="imgCode" label="图片验证码">
|
||||||
|
<image-code ref="imageCodeRef" v-model:value="formState.imgCode" v-model:random-str="formState.randomStr"></image-code>
|
||||||
|
</a-form-item>
|
||||||
|
|
||||||
|
<a-form-item has-feedback name="password" label="新密码">
|
||||||
|
<a-input-password v-model:value="formState.password" placeholder="新密码" size="large" autocomplete="off">
|
||||||
|
<template #prefix>
|
||||||
|
<fs-icon icon="ion:lock-closed-outline"></fs-icon>
|
||||||
|
</template>
|
||||||
|
</a-input-password>
|
||||||
|
</a-form-item>
|
||||||
|
<a-form-item has-feedback name="confirmPassword" label="确认密码">
|
||||||
|
<a-input-password v-model:value="formState.confirmPassword" placeholder="确认密码" size="large" autocomplete="off">
|
||||||
|
<template #prefix>
|
||||||
|
<fs-icon icon="ion:lock-closed-outline"></fs-icon>
|
||||||
|
</template>
|
||||||
|
</a-input-password>
|
||||||
|
</a-form-item>
|
||||||
|
<a-form-item>
|
||||||
|
<a-button type="primary" size="large" html-type="submit" class="submit-button"> 找回密码</a-button>
|
||||||
|
|
||||||
|
<div class="mt-2">
|
||||||
|
<a href="https://certd.docmirror.cn/guide/use/forgotpasswd/" target="_blank"> 管理员无绑定通信方式或MFA丢失找回 </a>
|
||||||
|
</div>
|
||||||
|
</a-form-item>
|
||||||
|
</a-form>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { onMounted, reactive, ref, toRaw, watch } from "vue";
|
||||||
|
import ImageCode from "/@/views/framework/login/image-code.vue";
|
||||||
|
import EmailCode from "/@/views/framework/register/email-code.vue";
|
||||||
|
import SmsCode from "/@/views/framework/login/sms-code.vue";
|
||||||
|
import { utils } from "@fast-crud/fast-crud";
|
||||||
|
import { useUserStore } from "/@/store/user";
|
||||||
|
|
||||||
|
defineOptions({
|
||||||
|
name: "ForgotPasswordPage",
|
||||||
|
});
|
||||||
|
|
||||||
|
const rules = {
|
||||||
|
input: [{ required: true }],
|
||||||
|
validateCode: [{ required: true }],
|
||||||
|
imgCode: [{ required: true }, { min: 4, max: 4, message: "请输入4位图片验证码" }],
|
||||||
|
password: [
|
||||||
|
{ required: true, trigger: "change", message: "请输入密码" },
|
||||||
|
{ min: 6, message: "至少输入6位密码" },
|
||||||
|
],
|
||||||
|
confirmPassword: [
|
||||||
|
{ required: true, trigger: "change", message: "请确认密码" },
|
||||||
|
{
|
||||||
|
validator: async (rule: any, value: any) => {
|
||||||
|
if (value && value !== formState.password) {
|
||||||
|
throw new Error("两次输入密码不一致");
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
};
|
||||||
|
const layout = {
|
||||||
|
labelCol: {
|
||||||
|
span: 0,
|
||||||
|
},
|
||||||
|
wrapperCol: {
|
||||||
|
span: 24,
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
||||||
|
const forgotPasswordType = ref();
|
||||||
|
const userStore = useUserStore();
|
||||||
|
const formRef = ref();
|
||||||
|
const imageCodeRef = ref();
|
||||||
|
|
||||||
|
const formState: any = reactive({
|
||||||
|
input: "",
|
||||||
|
randomStr: "",
|
||||||
|
imgCode: "",
|
||||||
|
phoneCode: "86",
|
||||||
|
validateCode: "",
|
||||||
|
|
||||||
|
password: "",
|
||||||
|
confirmPassword: "",
|
||||||
|
});
|
||||||
|
|
||||||
|
// TODO 这里配置不同的找回方式
|
||||||
|
onMounted(() => {
|
||||||
|
forgotPasswordType.value = "email";
|
||||||
|
});
|
||||||
|
|
||||||
|
// 监控找回类型变化
|
||||||
|
watch(forgotPasswordType, () => {
|
||||||
|
formState.input = "";
|
||||||
|
formState.validateCode = "";
|
||||||
|
imageCodeRef.value.resetImageCode();
|
||||||
|
formRef.value.clearValidate(Object.keys(formState).filter(key => !["password", "confirmPassword"].includes(key)));
|
||||||
|
});
|
||||||
|
|
||||||
|
const handleFinish = async (values: any) => {
|
||||||
|
await userStore.forgotPassword(
|
||||||
|
toRaw({
|
||||||
|
type: forgotPasswordType.value,
|
||||||
|
input: formState.input,
|
||||||
|
randomStr: formState.randomStr,
|
||||||
|
imgCode: formState.imgCode,
|
||||||
|
validateCode: formState.validateCode,
|
||||||
|
password: formState.password,
|
||||||
|
confirmPassword: formState.confirmPassword,
|
||||||
|
}) as any
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
const handleFinishFailed = (errors: any) => {
|
||||||
|
utils.logger.log(errors);
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style scoped lang="less">
|
||||||
|
.forgot-password-page {
|
||||||
|
.user-layout-forgot-password {
|
||||||
|
.submit-button {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -29,6 +29,10 @@
|
|||||||
</a-tag>
|
</a-tag>
|
||||||
</a-badge>
|
</a-badge>
|
||||||
<a-divider type="vertical" />
|
<a-divider type="vertical" />
|
||||||
|
<a-tag color="blue" class="flex-inline pointer mr-0" @click="openChangeLogUrl()">
|
||||||
|
{{ t("certd.dashboard.changeLog") }}
|
||||||
|
</a-tag>
|
||||||
|
<a-divider type="vertical" />
|
||||||
<vip-button mode="nav" style="font-size: 12px"></vip-button>
|
<vip-button mode="nav" style="font-size: 12px"></vip-button>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="settingsStore.isComm">
|
<template v-if="settingsStore.isComm">
|
||||||
@@ -152,32 +156,48 @@ import * as api from "./api";
|
|||||||
import { useI18n } from "/src/locales";
|
import { useI18n } from "/src/locales";
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
import { usePluginStore } from "/@/store/plugin";
|
import { usePluginStore } from "/@/store/plugin";
|
||||||
|
import { notification } from "ant-design-vue";
|
||||||
defineOptions({
|
defineOptions({
|
||||||
name: "DashboardUser",
|
name: "DashboardUser",
|
||||||
});
|
});
|
||||||
|
|
||||||
const version = ref(import.meta.env.VITE_APP_VERSION);
|
const version = ref(import.meta.env.VITE_APP_VERSION);
|
||||||
const latestVersion = ref("");
|
const latestVersion = ref("");
|
||||||
const hasNewVersion = computed(() => {
|
|
||||||
if (!latestVersion.value) {
|
function isNewVersion(version: string, latestVersion: string) {
|
||||||
|
if (!latestVersion) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (latestVersion.value === version.value) {
|
if (latestVersion === version) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
//分段比较
|
//分段比较
|
||||||
const current = version.value.split(".");
|
const current = version.split(".");
|
||||||
const latest = latestVersion.value.split(".");
|
const latest = latestVersion.split(".");
|
||||||
for (let i = 0; i < current.length; i++) {
|
for (let i = 0; i < current.length; i++) {
|
||||||
if (parseInt(latest[i]) < parseInt(current[i])) {
|
if (parseInt(latest[i]) > parseInt(current[i])) {
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
const hasNewVersion = computed(() => {
|
||||||
|
return isNewVersion(version.value, latestVersion.value);
|
||||||
});
|
});
|
||||||
async function loadLatestVersion() {
|
async function loadLatestVersion() {
|
||||||
latestVersion.value = await api.GetLatestVersion();
|
latestVersion.value = await api.GetLatestVersion();
|
||||||
console.log("latestVersion", latestVersion.value);
|
console.log("latestVersion", latestVersion.value);
|
||||||
|
|
||||||
|
const minVersion = settingsStore.productInfo?.app?.minVersion;
|
||||||
|
if (minVersion) {
|
||||||
|
//
|
||||||
|
if (isNewVersion(version.value, minVersion)) {
|
||||||
|
notification.error({
|
||||||
|
message: settingsStore.productInfo?.app?.minVersionTip ?? "版本过低,为了您的数据安全,请尽快升级",
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
const settingStore = useSettingStore();
|
const settingStore = useSettingStore();
|
||||||
const siteInfo: Ref<SiteInfo> = computed(() => {
|
const siteInfo: Ref<SiteInfo> = computed(() => {
|
||||||
@@ -214,6 +234,7 @@ function transformStatusCount() {
|
|||||||
{ name: "error", label: "失败" },
|
{ name: "error", label: "失败" },
|
||||||
{ name: "canceled", label: "已取消" },
|
{ name: "canceled", label: "已取消" },
|
||||||
{ name: null, label: "未执行" },
|
{ name: null, label: "未执行" },
|
||||||
|
{ name: "skip", label: "跳过" },
|
||||||
];
|
];
|
||||||
const result = [];
|
const result = [];
|
||||||
for (const item of sorted) {
|
for (const item of sorted) {
|
||||||
@@ -254,6 +275,9 @@ onMounted(async () => {
|
|||||||
function openUpgradeUrl() {
|
function openUpgradeUrl() {
|
||||||
window.open("https://certd.docmirror.cn/guide/install/upgrade.html");
|
window.open("https://certd.docmirror.cn/guide/install/upgrade.html");
|
||||||
}
|
}
|
||||||
|
function openChangeLogUrl() {
|
||||||
|
window.open("https://certd.docmirror.cn/guide/changelogs/CHANGELOG.html");
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="less">
|
<style lang="less">
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ const slots = defineSlots();
|
|||||||
.data-item {
|
.data-item {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
height: 180px;
|
height: 188px;
|
||||||
.header {
|
.header {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, useAttrs } from "vue";
|
import { ref, useAttrs, defineExpose } from "vue";
|
||||||
import { nanoid } from "nanoid";
|
import { nanoid } from "nanoid";
|
||||||
|
|
||||||
const props = defineProps<{
|
const props = defineProps<{
|
||||||
@@ -32,5 +32,10 @@ function resetImageCode() {
|
|||||||
imageCodeUrl.value = url + "?randomStr=" + randomStr;
|
imageCodeUrl.value = url + "?randomStr=" + randomStr;
|
||||||
emit("update:randomStr", randomStr);
|
emit("update:randomStr", randomStr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
resetImageCode,
|
||||||
|
})
|
||||||
|
|
||||||
resetImageCode();
|
resetImageCode();
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -47,10 +47,10 @@
|
|||||||
{{ t("authentication.loginButton") }}
|
{{ t("authentication.loginButton") }}
|
||||||
</a-button>
|
</a-button>
|
||||||
|
|
||||||
<div v-if="!settingStore.isComm" class="mt-2">
|
<div v-if="!!settingStore.sysPublic.selfServicePasswordRetrievalEnabled" class="mt-2">
|
||||||
<a href="https://certd.docmirror.cn/guide/use/forgotpasswd/" target="_blank">
|
<router-link :to="{ name: 'forgotPassword' }">
|
||||||
{{ t("authentication.forgotAdminPassword") }}
|
{{ t("authentication.forgotPassword") }}
|
||||||
</a>
|
</router-link>
|
||||||
</div>
|
</div>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
|
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ const props = defineProps<{
|
|||||||
phoneCode?: string;
|
phoneCode?: string;
|
||||||
imgCode?: string;
|
imgCode?: string;
|
||||||
randomStr?: string;
|
randomStr?: string;
|
||||||
|
verificationType?: string;
|
||||||
}>();
|
}>();
|
||||||
const emit = defineEmits(["update:value", "change"]);
|
const emit = defineEmits(["update:value", "change"]);
|
||||||
|
|
||||||
@@ -58,6 +59,7 @@ async function sendSmsCode() {
|
|||||||
mobile: props.mobile,
|
mobile: props.mobile,
|
||||||
imgCode: props.imgCode,
|
imgCode: props.imgCode,
|
||||||
randomStr: props.randomStr,
|
randomStr: props.randomStr,
|
||||||
|
verificationType: props.verificationType,
|
||||||
});
|
});
|
||||||
} finally {
|
} finally {
|
||||||
loading.value = false;
|
loading.value = false;
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ const props = defineProps<{
|
|||||||
email?: string;
|
email?: string;
|
||||||
imgCode?: string;
|
imgCode?: string;
|
||||||
randomStr?: string;
|
randomStr?: string;
|
||||||
|
verificationType?: string;
|
||||||
}>();
|
}>();
|
||||||
const emit = defineEmits(["update:value", "change"]);
|
const emit = defineEmits(["update:value", "change"]);
|
||||||
|
|
||||||
@@ -53,6 +54,7 @@ async function sendSmsCode() {
|
|||||||
email: props.email,
|
email: props.email,
|
||||||
imgCode: props.imgCode,
|
imgCode: props.imgCode,
|
||||||
randomStr: props.randomStr,
|
randomStr: props.randomStr,
|
||||||
|
verificationType: props.verificationType,
|
||||||
});
|
});
|
||||||
} finally {
|
} finally {
|
||||||
loading.value = false;
|
loading.value = false;
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
import * as api from "./api";
|
import * as api from "./api";
|
||||||
import { AddReq, compute, CreateCrudOptionsProps, CreateCrudOptionsRet, DelReq, dict, EditReq, UserPageQuery, UserPageRes } from "@fast-crud/fast-crud";
|
import { AddReq, CreateCrudOptionsProps, CreateCrudOptionsRet, DelReq, dict, EditReq, UserPageQuery, UserPageRes } from "@fast-crud/fast-crud";
|
||||||
import { useUserStore } from "/@/store/user";
|
import { useUserStore } from "/@/store/user";
|
||||||
import { Modal, notification } from "ant-design-vue";
|
import { Modal, notification } from "ant-design-vue";
|
||||||
import dayjs from "dayjs";
|
import dayjs from "dayjs";
|
||||||
import { useSettingStore } from "/@/store/settings";
|
import { useSettingStore } from "/@/store/settings";
|
||||||
import { useI18n } from "/src/locales";
|
import { useI18n } from "/src/locales";
|
||||||
|
import { computed } from "vue";
|
||||||
|
|
||||||
export default function ({ crudExpose }: CreateCrudOptionsProps): CreateCrudOptionsRet {
|
export default function ({ crudExpose }: CreateCrudOptionsProps): CreateCrudOptionsRet {
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
@@ -26,7 +27,7 @@ export default function ({ crudExpose }: CreateCrudOptionsProps): CreateCrudOpti
|
|||||||
const userStore = useUserStore();
|
const userStore = useUserStore();
|
||||||
|
|
||||||
const settingStore = useSettingStore();
|
const settingStore = useSettingStore();
|
||||||
const userValidTimeEnabled = compute(() => {
|
const userValidTimeEnabled = computed(() => {
|
||||||
return settingStore.sysPublic.userValidTimeEnabled === true;
|
return settingStore.sysPublic.userValidTimeEnabled === true;
|
||||||
});
|
});
|
||||||
return {
|
return {
|
||||||
@@ -226,7 +227,7 @@ export default function ({ crudExpose }: CreateCrudOptionsProps): CreateCrudOpti
|
|||||||
column: {
|
column: {
|
||||||
align: "center",
|
align: "center",
|
||||||
sorter: true,
|
sorter: true,
|
||||||
width: 100,
|
width: 160,
|
||||||
show: userValidTimeEnabled,
|
show: userValidTimeEnabled,
|
||||||
cellRender({ value }) {
|
cellRender({ value }) {
|
||||||
if (value == null || value === 0) {
|
if (value == null || value === 0) {
|
||||||
|
|||||||
@@ -47,6 +47,10 @@
|
|||||||
<div class="helper" v-html="t('certd.commonCnameHelper')"></div>
|
<div class="helper" v-html="t('certd.commonCnameHelper')"></div>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
|
|
||||||
|
<a-form-item :label="t('certd.enableCommonSelfServicePasswordRetrieval')" :name="['public', 'selfServicePasswordRetrievalEnabled']">
|
||||||
|
<a-switch v-model:checked="formState.public.selfServicePasswordRetrievalEnabled" />
|
||||||
|
</a-form-item>
|
||||||
|
|
||||||
<a-form-item label=" " :colon="false" :wrapper-col="{ span: 8 }">
|
<a-form-item label=" " :colon="false" :wrapper-col="{ span: 8 }">
|
||||||
<a-button :loading="saveLoading" type="primary" html-type="submit">{{ t("certd.saveButton") }}</a-button>
|
<a-button :loading="saveLoading" type="primary" html-type="submit">{{ t("certd.saveButton") }}</a-button>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
|
|||||||
@@ -3,6 +3,74 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [1.36.14](https://github.com/certd/certd/compare/v1.36.13...v1.36.14) (2025-07-28)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 授权管理支持模糊查询 ([866eb62](https://github.com/certd/certd/commit/866eb6241baa7b21f6eddc649966324c188236c6))
|
||||||
|
* 新增找回密码功能 [@nicheng-he](https://github.com/nicheng-he) ([81ac240](https://github.com/certd/certd/commit/81ac240ac84db0af2f56b6352e227ecb49f38377))
|
||||||
|
* 运行主机脚本插件支持选择运行策略 ([86b3df1](https://github.com/certd/certd/commit/86b3df194126476e1f58e0952a77e986f62eecce))
|
||||||
|
|
||||||
|
## [1.36.13](https://github.com/certd/certd/compare/v1.36.12...v1.36.13) (2025-07-23)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 阿里云部分插件优化 [@nicheng-he](https://github.com/nicheng-he) ([e3738f6](https://github.com/certd/certd/commit/e3738f6422270d75ec414c15a343248cc4cad6e1))
|
||||||
|
|
||||||
|
## [1.36.12](https://github.com/certd/certd/compare/v1.36.11...v1.36.12) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 上传到阿里云cas,证书前缀无效的bug ([b382351](https://github.com/certd/certd/commit/b382351c7b91ec10e1f61d94bec5aad075207ec8))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署到k8s,tke,ack忽悠证书校验 ([ab84835](https://github.com/certd/certd/commit/ab848353621869464a2c9a45fdb5e28d998b8a58))
|
||||||
|
|
||||||
|
## [1.36.11](https://github.com/certd/certd/compare/v1.36.10...v1.36.11) (2025-07-22)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 安全更新,备份数据库插件仅限管理员运行 ([13dfca1](https://github.com/certd/certd/commit/13dfca1749275526c82465a17c482b607c820fdd))
|
||||||
|
|
||||||
|
## [1.36.10](https://github.com/certd/certd/compare/v1.36.9...v1.36.10) (2025-07-18)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 企业微信通知改成text类型,因为markdown类型不支持@用户 ([747d266](https://github.com/certd/certd/commit/747d26674248082e678a3fd5ecc94712641a2716))
|
||||||
|
* api接口获取不到证书的bug ([05a33a0](https://github.com/certd/certd/commit/05a33a0ec9999e2802f6c7b23cc1c61a2b9e963d))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 部署到阿里云oss插件支持选择上传到阿里云cas中的证书 ([2ea2c8c](https://github.com/certd/certd/commit/2ea2c8c05fc40f79595f1bbde67c1413558bf684))
|
||||||
|
* 账号即将过期通知 ([e403450](https://github.com/certd/certd/commit/e40345095f31e2fb8e2333a6647466659133fa0c))
|
||||||
|
* 子域名托管重复域名不允许添加 ([ffc0c7b](https://github.com/certd/certd/commit/ffc0c7bb7b16d9904fd2d905d1c4e1d4854e92a9))
|
||||||
|
|
||||||
|
## [1.36.9](https://github.com/certd/certd/compare/v1.36.7...v1.36.9) (2025-07-15)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @certd/ui-server
|
||||||
|
|
||||||
|
## [1.36.7](https://github.com/certd/certd/compare/v1.36.6...v1.36.7) (2025-07-15)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 修复流水线列表页报length错误的bug ([9864792](https://github.com/certd/certd/commit/9864792bbfd149e770d6e1ffa809573694f99dd3))
|
||||||
|
* 修复流水线页面状态没有刷新的bug ([93e9498](https://github.com/certd/certd/commit/93e9498b410353f504e11e264db62468895d7290))
|
||||||
|
* 修复自定义证书检查时间重启之后不生效的bug ([38e867c](https://github.com/certd/certd/commit/38e867c917bbc68bd228bdd8064f3e7358d6413d))
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 支持上传证书到各种对象存储,oss、cos、七牛、s3、minio等 ([1da8617](https://github.com/certd/certd/commit/1da8617a53a675776635bbc3bcb3c6d7dff83e27))
|
||||||
|
* 支持邮箱发送证书 ([95332d5](https://github.com/certd/certd/commit/95332d5db96cd54ddab6ab737332417a09169b39))
|
||||||
|
|
||||||
|
## [1.36.6](https://github.com/certd/certd/compare/v1.36.5...v1.36.6) (2025-07-14)
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* 优化流水线列表页面、详情页面性能,精简返回数据 ([609ac9c](https://github.com/certd/certd/commit/609ac9c9a2dde605eb09834ae59693c1cb238765))
|
||||||
|
* 支持自动选择校验方式申请证书 ([3f99432](https://github.com/certd/certd/commit/3f9943270cfb12946e38e6272bc5e8d95ad6ab9e))
|
||||||
|
* OpenAPI支持autoApply参数 ([42f4d14](https://github.com/certd/certd/commit/42f4d1477dc791520a874aed56035abcbc8c433b))
|
||||||
|
|
||||||
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
## [1.36.5](https://github.com/certd/certd/compare/v1.36.4...v1.36.5) (2025-07-11)
|
||||||
|
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
|||||||
20
packages/ui/certd-server/db/migration-mysql/v10027__auto.sql
Normal file
20
packages/ui/certd-server/db/migration-mysql/v10027__auto.sql
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
DROP TABLE IF EXISTS `cd_domain`;
|
||||||
|
CREATE TABLE `cd_domain`
|
||||||
|
(
|
||||||
|
`id` bigint PRIMARY KEY AUTO_INCREMENT NOT NULL,
|
||||||
|
`user_id` bigint,
|
||||||
|
`domain` varchar(512),
|
||||||
|
challenge_type varchar(50),
|
||||||
|
dns_provider_type varchar(50),
|
||||||
|
dns_provider_access bigint,
|
||||||
|
http_uploader_type varchar(50),
|
||||||
|
http_uploader_access bigint,
|
||||||
|
http_upload_root_dir varchar(512),
|
||||||
|
`disabled` boolean NOT NULL DEFAULT false,
|
||||||
|
`create_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`update_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE INDEX `index_domain_user_id` ON `cd_domain` (`user_id`);
|
||||||
|
CREATE INDEX `index_domain_domain` ON `cd_domain` (`domain`);
|
||||||
|
|
||||||
20
packages/ui/certd-server/db/migration-pg/v10027__auto.sql
Normal file
20
packages/ui/certd-server/db/migration-pg/v10027__auto.sql
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
DROP TABLE IF EXISTS "cd_domain";
|
||||||
|
CREATE TABLE "cd_domain"
|
||||||
|
(
|
||||||
|
"id" bigint PRIMARY KEY GENERATED BY DEFAULT AS IDENTITY NOT NULL,
|
||||||
|
"user_id" bigint,
|
||||||
|
"domain" varchar(512),
|
||||||
|
challenge_type varchar(50),
|
||||||
|
dns_provider_type varchar(50),
|
||||||
|
dns_provider_access bigint,
|
||||||
|
http_uploader_type varchar(50),
|
||||||
|
http_uploader_access bigint,
|
||||||
|
http_upload_root_dir varchar(512),
|
||||||
|
"disabled" boolean NOT NULL DEFAULT (false),
|
||||||
|
"create_time" timestamp NOT NULL DEFAULT (CURRENT_TIMESTAMP),
|
||||||
|
"update_time" timestamp NOT NULL DEFAULT (CURRENT_TIMESTAMP)
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE INDEX "index_domain_user_id" ON "cd_domain" ("user_id");
|
||||||
|
CREATE INDEX "index_domain_domain" ON "cd_domain" ("domain");
|
||||||
|
|
||||||
@@ -1,8 +1,9 @@
|
|||||||
|
DROP TABLE IF EXISTS "cd_domain";
|
||||||
CREATE TABLE "cd_domain"
|
CREATE TABLE "cd_domain"
|
||||||
(
|
(
|
||||||
"id" integer PRIMARY KEY AUTOINCREMENT NOT NULL,
|
"id" integer PRIMARY KEY AUTOINCREMENT NOT NULL,
|
||||||
"user_id" integer,
|
"user_id" integer,
|
||||||
"domain" varchar(1024),
|
"domain" varchar(512),
|
||||||
challenge_type varchar(50),
|
challenge_type varchar(50),
|
||||||
dns_provider_type varchar(50),
|
dns_provider_type varchar(50),
|
||||||
dns_provider_access bigint,
|
dns_provider_access bigint,
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@certd/ui-server",
|
"name": "@certd/ui-server",
|
||||||
"version": "1.36.5",
|
"version": "1.36.14",
|
||||||
"description": "fast-server base midway",
|
"description": "fast-server base midway",
|
||||||
"private": true,
|
"private": true,
|
||||||
"type": "module",
|
"type": "module",
|
||||||
@@ -42,20 +42,20 @@
|
|||||||
"@aws-sdk/client-cloudfront": "^3.699.0",
|
"@aws-sdk/client-cloudfront": "^3.699.0",
|
||||||
"@aws-sdk/client-iam": "^3.699.0",
|
"@aws-sdk/client-iam": "^3.699.0",
|
||||||
"@aws-sdk/client-s3": "^3.705.0",
|
"@aws-sdk/client-s3": "^3.705.0",
|
||||||
"@certd/acme-client": "^1.36.5",
|
"@certd/acme-client": "^1.36.14",
|
||||||
"@certd/basic": "^1.36.5",
|
"@certd/basic": "^1.36.14",
|
||||||
"@certd/commercial-core": "^1.36.5",
|
"@certd/commercial-core": "^1.36.14",
|
||||||
"@certd/cv4pve-api-javascript": "^8.4.1",
|
"@certd/cv4pve-api-javascript": "^8.4.1",
|
||||||
"@certd/jdcloud": "^1.36.5",
|
"@certd/jdcloud": "^1.36.14",
|
||||||
"@certd/lib-huawei": "^1.36.5",
|
"@certd/lib-huawei": "^1.36.14",
|
||||||
"@certd/lib-k8s": "^1.36.5",
|
"@certd/lib-k8s": "^1.36.14",
|
||||||
"@certd/lib-server": "^1.36.5",
|
"@certd/lib-server": "^1.36.14",
|
||||||
"@certd/midway-flyway-js": "^1.36.5",
|
"@certd/midway-flyway-js": "^1.36.14",
|
||||||
"@certd/pipeline": "^1.36.5",
|
"@certd/pipeline": "^1.36.14",
|
||||||
"@certd/plugin-cert": "^1.36.5",
|
"@certd/plugin-cert": "^1.36.14",
|
||||||
"@certd/plugin-lib": "^1.36.5",
|
"@certd/plugin-lib": "^1.36.14",
|
||||||
"@certd/plugin-plus": "^1.36.5",
|
"@certd/plugin-plus": "^1.36.14",
|
||||||
"@certd/plus-core": "^1.36.5",
|
"@certd/plus-core": "^1.36.14",
|
||||||
"@huaweicloud/huaweicloud-sdk-cdn": "^3.1.120",
|
"@huaweicloud/huaweicloud-sdk-cdn": "^3.1.120",
|
||||||
"@huaweicloud/huaweicloud-sdk-core": "^3.1.120",
|
"@huaweicloud/huaweicloud-sdk-core": "^3.1.120",
|
||||||
"@koa/cors": "^5.0.0",
|
"@koa/cors": "^5.0.0",
|
||||||
|
|||||||
@@ -27,6 +27,9 @@ export class EmailCodeReq {
|
|||||||
|
|
||||||
@Rule(RuleType.string().required().max(4))
|
@Rule(RuleType.string().required().max(4))
|
||||||
imgCode: string;
|
imgCode: string;
|
||||||
|
|
||||||
|
@Rule(RuleType.string())
|
||||||
|
verificationType: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -55,8 +58,20 @@ export class BasicController extends BaseController {
|
|||||||
@Body(ALL)
|
@Body(ALL)
|
||||||
body: EmailCodeReq
|
body: EmailCodeReq
|
||||||
) {
|
) {
|
||||||
|
const opts = {
|
||||||
|
verificationType: body.verificationType,
|
||||||
|
title: undefined,
|
||||||
|
content: undefined,
|
||||||
|
duration: undefined,
|
||||||
|
};
|
||||||
|
if(body?.verificationType === 'forgotPassword') {
|
||||||
|
opts.title = '找回密码';
|
||||||
|
opts.content = '验证码:${code}。您正在找回密码,请输入验证码并完成操作。如非本人操作请忽略';
|
||||||
|
opts.duration = 3;
|
||||||
|
}
|
||||||
|
|
||||||
await this.codeService.checkCaptcha(body.randomStr, body.imgCode);
|
await this.codeService.checkCaptcha(body.randomStr, body.imgCode);
|
||||||
await this.codeService.sendEmailCode(body.email, body.randomStr);
|
await this.codeService.sendEmailCode(body.email, body.randomStr, opts);
|
||||||
// 设置缓存内容
|
// 设置缓存内容
|
||||||
return this.ok(null);
|
return this.ok(null);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,13 +1,15 @@
|
|||||||
import { ALL, Body, Controller, Get, Inject, Post, Provide, Query } from '@midwayjs/core';
|
import { ALL, Body, Controller, Get, Inject, Post, Provide, Query } from "@midwayjs/core";
|
||||||
import { CodeException, Constants, EncryptService } from '@certd/lib-server';
|
import { CodeException, Constants, EncryptService } from "@certd/lib-server";
|
||||||
import { CertInfoService } from '../../../modules/monitor/service/cert-info-service.js';
|
import { CertInfo } from "@certd/plugin-cert";
|
||||||
import { CertInfo } from '@certd/plugin-cert';
|
import { OpenKey } from "../../../modules/open/service/open-key-service.js";
|
||||||
import { OpenKey } from '../../../modules/open/service/open-key-service.js';
|
import { BaseOpenController } from "../base-open-controller.js";
|
||||||
import { BaseOpenController } from '../base-open-controller.js';
|
import { CertInfoFacade } from "../../../modules/monitor/facade/cert-info-facade.js";
|
||||||
|
import { merge } from "lodash-es";
|
||||||
|
|
||||||
export type CertGetReq = {
|
export type CertGetReq = {
|
||||||
domains?: string;
|
domains?: string;
|
||||||
certId: number;
|
certId: number;
|
||||||
|
autoApply?:boolean;
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -16,7 +18,7 @@ export type CertGetReq = {
|
|||||||
@Controller('/api/v1/cert')
|
@Controller('/api/v1/cert')
|
||||||
export class OpenCertController extends BaseOpenController {
|
export class OpenCertController extends BaseOpenController {
|
||||||
@Inject()
|
@Inject()
|
||||||
certInfoService: CertInfoService;
|
certInfoFacade: CertInfoFacade;
|
||||||
@Inject()
|
@Inject()
|
||||||
encryptService: EncryptService;
|
encryptService: EncryptService;
|
||||||
|
|
||||||
@@ -29,10 +31,13 @@ export class OpenCertController extends BaseOpenController {
|
|||||||
throw new CodeException(Constants.res.openKeyError);
|
throw new CodeException(Constants.res.openKeyError);
|
||||||
}
|
}
|
||||||
|
|
||||||
const res: CertInfo = await this.certInfoService.getCertInfo({
|
const req = merge({}, bean, query)
|
||||||
|
|
||||||
|
const res: CertInfo = await this.certInfoFacade.getCertInfo({
|
||||||
userId,
|
userId,
|
||||||
domains: bean.domains || query.domains,
|
domains: req.domains,
|
||||||
certId: bean.certId || query.certId,
|
certId: req.certId,
|
||||||
|
autoApply: req.autoApply??false,
|
||||||
});
|
});
|
||||||
return this.ok(res);
|
return this.ok(res);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,56 @@
|
|||||||
|
import { ALL, Body, Controller, Inject, Post, Provide } from '@midwayjs/core';
|
||||||
|
import { BaseController, CommonException, Constants, SysSettingsService } from "@certd/lib-server";
|
||||||
|
import { CodeService } from '../../../modules/basic/service/code-service.js';
|
||||||
|
import { UserService } from '../../../modules/sys/authority/service/user-service.js';
|
||||||
|
import { LoginService } from "../../../modules/login/service/login-service.js";
|
||||||
|
|
||||||
|
/**
|
||||||
|
*/
|
||||||
|
@Provide()
|
||||||
|
@Controller('/api')
|
||||||
|
export class LoginController extends BaseController {
|
||||||
|
@Inject()
|
||||||
|
loginService: LoginService;
|
||||||
|
@Inject()
|
||||||
|
userService: UserService;
|
||||||
|
@Inject()
|
||||||
|
codeService: CodeService;
|
||||||
|
|
||||||
|
@Inject()
|
||||||
|
sysSettingsService: SysSettingsService;
|
||||||
|
|
||||||
|
@Post('/forgotPassword', { summary: Constants.per.guest })
|
||||||
|
public async forgotPassword(
|
||||||
|
@Body(ALL)
|
||||||
|
body: any,
|
||||||
|
) {
|
||||||
|
const sysSettings = await this.sysSettingsService.getPublicSettings();
|
||||||
|
if(!sysSettings.selfServicePasswordRetrievalEnabled) {
|
||||||
|
throw new CommonException('暂未开启自助找回');
|
||||||
|
}
|
||||||
|
|
||||||
|
if(body.type === 'email') {
|
||||||
|
this.codeService.checkEmailCode({
|
||||||
|
verificationType: 'forgotPassword',
|
||||||
|
email: body.input,
|
||||||
|
randomStr: body.randomStr,
|
||||||
|
validateCode: body.validateCode,
|
||||||
|
throwError: true,
|
||||||
|
});
|
||||||
|
} else if(body.type === 'mobile') {
|
||||||
|
await this.codeService.checkSmsCode({
|
||||||
|
verificationType: 'forgotPassword',
|
||||||
|
mobile: body.input,
|
||||||
|
randomStr: body.randomStr,
|
||||||
|
phoneCode: body.phoneCode,
|
||||||
|
smsCode: body.validateCode,
|
||||||
|
throwError: true,
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
throw new CommonException('暂不支持的找回类型,请联系管理员找回');
|
||||||
|
}
|
||||||
|
const username = await this.userService.forgotPassword(body);
|
||||||
|
username && this.loginService.clearCacheOnSuccess(username)
|
||||||
|
return this.ok();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -23,8 +23,13 @@ export class AccessController extends CrudController<AccessService> {
|
|||||||
async page(@Body(ALL) body) {
|
async page(@Body(ALL) body) {
|
||||||
body.query = body.query ?? {};
|
body.query = body.query ?? {};
|
||||||
delete body.query.userId;
|
delete body.query.userId;
|
||||||
|
body.query.userId = this.getUserId()
|
||||||
|
let name = body.query?.name;
|
||||||
|
delete body.query.name;
|
||||||
const buildQuery = qb => {
|
const buildQuery = qb => {
|
||||||
qb.andWhere('user_id = :userId', { userId: this.getUserId() });
|
if (name) {
|
||||||
|
qb.andWhere('name like :name', { name: `%${name.trim()}%` });
|
||||||
|
}
|
||||||
};
|
};
|
||||||
const res = await this.service.page({
|
const res = await this.service.page({
|
||||||
query: body.query,
|
query: body.query,
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ import {EmailService} from '../../../modules/basic/service/email-service.js';
|
|||||||
import {http, HttpRequestConfig, logger, mergeUtils, utils} from '@certd/basic';
|
import {http, HttpRequestConfig, logger, mergeUtils, utils} from '@certd/basic';
|
||||||
import {NotificationService} from '../../../modules/pipeline/service/notification-service.js';
|
import {NotificationService} from '../../../modules/pipeline/service/notification-service.js';
|
||||||
import {TaskServiceBuilder} from "../../../modules/pipeline/service/getter/task-service-getter.js";
|
import {TaskServiceBuilder} from "../../../modules/pipeline/service/getter/task-service-getter.js";
|
||||||
|
import { cloneDeep } from 'lodash-es';
|
||||||
|
|
||||||
@Provide()
|
@Provide()
|
||||||
@Controller('/api/pi/handle')
|
@Controller('/api/pi/handle')
|
||||||
@@ -103,6 +104,7 @@ export class HandleController extends BaseController {
|
|||||||
const taskCtx: TaskInstanceContext = {
|
const taskCtx: TaskInstanceContext = {
|
||||||
pipeline: undefined,
|
pipeline: undefined,
|
||||||
step: undefined,
|
step: undefined,
|
||||||
|
define: cloneDeep( pluginDefine.define),
|
||||||
lastStatus: undefined,
|
lastStatus: undefined,
|
||||||
http,
|
http,
|
||||||
download,
|
download,
|
||||||
|
|||||||
@@ -1,16 +1,15 @@
|
|||||||
import { ALL, Body, Controller, Get, Inject, Post, Provide, Query } from '@midwayjs/core';
|
import { ALL, Body, Controller, Get, Inject, Post, Provide, Query } from "@midwayjs/core";
|
||||||
import { CommonException, Constants, CrudController, PermissionException } from '@certd/lib-server';
|
import { CommonException, Constants, CrudController, PermissionException, SysSettingsService } from "@certd/lib-server";
|
||||||
import { PipelineEntity } from '../../../modules/pipeline/entity/pipeline.js';
|
import { PipelineEntity } from "../../../modules/pipeline/entity/pipeline.js";
|
||||||
import { HistoryService } from '../../../modules/pipeline/service/history-service.js';
|
import { HistoryService } from "../../../modules/pipeline/service/history-service.js";
|
||||||
import { HistoryLogService } from '../../../modules/pipeline/service/history-log-service.js';
|
import { HistoryLogService } from "../../../modules/pipeline/service/history-log-service.js";
|
||||||
import { HistoryEntity } from '../../../modules/pipeline/entity/history.js';
|
import { HistoryEntity } from "../../../modules/pipeline/entity/history.js";
|
||||||
import { HistoryLogEntity } from '../../../modules/pipeline/entity/history-log.js';
|
import { HistoryLogEntity } from "../../../modules/pipeline/entity/history-log.js";
|
||||||
import { PipelineService } from '../../../modules/pipeline/service/pipeline-service.js';
|
import { PipelineService } from "../../../modules/pipeline/service/pipeline-service.js";
|
||||||
import * as fs from 'fs';
|
import * as fs from "fs";
|
||||||
import { logger } from '@certd/basic';
|
import { logger } from "@certd/basic";
|
||||||
import { AuthService } from '../../../modules/sys/authority/service/auth-service.js';
|
import { AuthService } from "../../../modules/sys/authority/service/auth-service.js";
|
||||||
import { SysSettingsService } from '@certd/lib-server';
|
import { In } from "typeorm";
|
||||||
import { In } from 'typeorm';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 证书
|
* 证书
|
||||||
@@ -88,11 +87,30 @@ export class HistoryController extends CrudController<HistoryService> {
|
|||||||
const buildQuery = qb => {
|
const buildQuery = qb => {
|
||||||
qb.limit(20);
|
qb.limit(20);
|
||||||
};
|
};
|
||||||
|
const withDetail = body.withDetail;
|
||||||
|
delete body.withDetail;
|
||||||
|
let select:any = null
|
||||||
|
if (!withDetail) {
|
||||||
|
select = {
|
||||||
|
pipeline: true, // 后面这里改成false
|
||||||
|
id: true,
|
||||||
|
userId: true,
|
||||||
|
pipelineId: true,
|
||||||
|
status: true,
|
||||||
|
// startTime: true,
|
||||||
|
triggerType: true,
|
||||||
|
endTime: true,
|
||||||
|
createTime: true,
|
||||||
|
updateTime: true
|
||||||
|
};
|
||||||
|
}
|
||||||
const listRet = await this.getService().list({
|
const listRet = await this.getService().list({
|
||||||
query: body,
|
query: body,
|
||||||
sort: { prop: 'id', asc: false },
|
sort: { prop: 'id', asc: false },
|
||||||
buildQuery,
|
buildQuery,
|
||||||
|
select
|
||||||
});
|
});
|
||||||
|
|
||||||
for (const item of listRet) {
|
for (const item of listRet) {
|
||||||
if (!item.pipeline) {
|
if (!item.pipeline) {
|
||||||
continue;
|
continue;
|
||||||
@@ -100,7 +118,13 @@ export class HistoryController extends CrudController<HistoryService> {
|
|||||||
const json = JSON.parse(item.pipeline);
|
const json = JSON.parse(item.pipeline);
|
||||||
delete json.stages;
|
delete json.stages;
|
||||||
item.pipeline = json;
|
item.pipeline = json;
|
||||||
|
|
||||||
|
//@ts-ignore
|
||||||
|
item.version = json.version;
|
||||||
|
item.status = json.status.result
|
||||||
|
delete item.pipeline;
|
||||||
}
|
}
|
||||||
|
|
||||||
return this.ok(listRet);
|
return this.ok(listRet);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,15 +1,16 @@
|
|||||||
import { Autoload, Config, Init, Inject, Scope, ScopeEnum } from '@midwayjs/core';
|
import {Autoload, Config, Init, Inject, Scope, ScopeEnum} from '@midwayjs/core';
|
||||||
import { PipelineService } from '../pipeline/service/pipeline-service.js';
|
import {PipelineService} from '../pipeline/service/pipeline-service.js';
|
||||||
import { logger } from '@certd/basic';
|
import {logger} from '@certd/basic';
|
||||||
import {SysSettingsService, SysSiteInfo} from '@certd/lib-server';
|
import {SysSettingsService, SysSiteInfo} from '@certd/lib-server';
|
||||||
import { SiteInfoService } from '../monitor/index.js';
|
import {SiteInfoService} from '../monitor/index.js';
|
||||||
import { Cron } from '../cron/cron.js';
|
import {Cron} from '../cron/cron.js';
|
||||||
import {UserSettingsService} from "../mine/service/user-settings-service.js";
|
import {UserSettingsService} from "../mine/service/user-settings-service.js";
|
||||||
import {UserSiteMonitorSetting} from "../mine/service/models.js";
|
import {UserSiteMonitorSetting} from "../mine/service/models.js";
|
||||||
import {getPlusInfo} from "@certd/plus-core";
|
import {getPlusInfo} from "@certd/plus-core";
|
||||||
import dayjs from "dayjs";
|
import dayjs from "dayjs";
|
||||||
import {NotificationService} from "../pipeline/service/notification-service.js";
|
import {NotificationService} from "../pipeline/service/notification-service.js";
|
||||||
import {UserService} from "../sys/authority/service/user-service.js";
|
import {UserService} from "../sys/authority/service/user-service.js";
|
||||||
|
import {Between} from "typeorm";
|
||||||
|
|
||||||
@Autoload()
|
@Autoload()
|
||||||
@Scope(ScopeEnum.Request, { allowDowngrade: true })
|
@Scope(ScopeEnum.Request, { allowDowngrade: true })
|
||||||
@@ -58,6 +59,8 @@ export class AutoCRegisterCron {
|
|||||||
|
|
||||||
|
|
||||||
await this.registerPlusExpireCheckCron();
|
await this.registerPlusExpireCheckCron();
|
||||||
|
|
||||||
|
await this.registerUserExpireCheckCron()
|
||||||
}
|
}
|
||||||
|
|
||||||
async registerSiteMonitorCron() {
|
async registerSiteMonitorCron() {
|
||||||
@@ -71,7 +74,7 @@ export class AutoCRegisterCron {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
for (const item of monitorSettingList) {
|
for (const item of monitorSettingList) {
|
||||||
const setting = item.setting ?? JSON.parse(item.setting)
|
const setting = item.setting ? JSON.parse(item.setting):{}
|
||||||
if(!setting?.cron){
|
if(!setting?.cron){
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
@@ -137,4 +140,61 @@ export class AutoCRegisterCron {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
registerUserExpireCheckCron() {
|
||||||
|
// 添加plus即将到期检查任务
|
||||||
|
this.cron.register({
|
||||||
|
name: 'user-expire-check',
|
||||||
|
cron: `0 20 9 * * *`, // 一天只能检查一次,否则会重复发送通知
|
||||||
|
job: async () => {
|
||||||
|
|
||||||
|
const getExpiresDaysUsers = async (days: number) => {
|
||||||
|
const targetDate = dayjs().add(days, 'day')
|
||||||
|
const startTime = targetDate.startOf('day').valueOf()
|
||||||
|
const endTime = targetDate.endOf('day').valueOf()
|
||||||
|
return await this.userService.find({
|
||||||
|
where: {
|
||||||
|
validTime: Between(startTime, endTime),
|
||||||
|
status: 1
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const notifyExpiresDaysUsers = async (days: number) => {
|
||||||
|
const list = await getExpiresDaysUsers(days)
|
||||||
|
if (list.length === 0) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
let title = `账号即将到期`
|
||||||
|
let content = `您的账号剩余${days}天到期,请及时续期,以免影响业务`
|
||||||
|
if (days <= 0) {
|
||||||
|
title = `账号已过期`
|
||||||
|
content = `您的账号已过期${Math.abs(days)}天,请尽快续期,以免影响业务`
|
||||||
|
}
|
||||||
|
const url = await this.notificationService.getBindUrl("");
|
||||||
|
for (const user of list) {
|
||||||
|
logger.info(`发送到期通知给用户:${user.username}`)
|
||||||
|
await this.notificationService.send({
|
||||||
|
useDefault: true,
|
||||||
|
logger: logger,
|
||||||
|
body: {
|
||||||
|
title,
|
||||||
|
content,
|
||||||
|
errorMessage: title,
|
||||||
|
url
|
||||||
|
}
|
||||||
|
}, user.id)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
await notifyExpiresDaysUsers(7)
|
||||||
|
await notifyExpiresDaysUsers(3)
|
||||||
|
await notifyExpiresDaysUsers(1)
|
||||||
|
await notifyExpiresDaysUsers(0)
|
||||||
|
await notifyExpiresDaysUsers(-1)
|
||||||
|
await notifyExpiresDaysUsers(-3)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user