From e1e7011853ad0c5bd7b09c3690861d5aa34b2db4 Mon Sep 17 00:00:00 2001 From: xiaojunnuo Date: Tue, 19 Aug 2025 17:06:14 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20ssh=20=E9=85=8D=E7=BD=AEsudo=E5=85=8D?= =?UTF-8?q?=E5=AF=86=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/ISSUE_TEMPLATE/{plugin.md => 1plugin.md} | 4 ++-- .github/ISSUE_TEMPLATE/{dns.md => 2dns.md} | 12 ++++++------ .github/ISSUE_TEMPLATE/{bug.md => 3bug.md} | 4 ++-- .github/ISSUE_TEMPLATE/{feature.md => 4feature.md} | 4 ++-- packages/plugins/plugin-lib/src/ssh/ssh.ts | 3 +++ 5 files changed, 15 insertions(+), 12 deletions(-) rename .github/ISSUE_TEMPLATE/{plugin.md => 1plugin.md} (86%) rename .github/ISSUE_TEMPLATE/{dns.md => 2dns.md} (61%) rename .github/ISSUE_TEMPLATE/{bug.md => 3bug.md} (86%) rename .github/ISSUE_TEMPLATE/{feature.md => 4feature.md} (82%) diff --git a/.github/ISSUE_TEMPLATE/plugin.md b/.github/ISSUE_TEMPLATE/1plugin.md similarity index 86% rename from .github/ISSUE_TEMPLATE/plugin.md rename to .github/ISSUE_TEMPLATE/1plugin.md index dc473210..0439f1c8 100644 --- a/.github/ISSUE_TEMPLATE/plugin.md +++ b/.github/ISSUE_TEMPLATE/1plugin.md @@ -1,11 +1,11 @@ --- name: Plugin Apply -about: 请求支持新部署插件 +about: 部署插件申请支持 title: "[Plugin] " labels: feature --- -> > 感谢您支持certd,请按如下规范提交issue +> > 感谢您支持certd,请按如下规范提交issue > 如果有条件,请尽量在[github上提交](https://github.com/certd/certd/issues) # 新部署插件申请支持 diff --git a/.github/ISSUE_TEMPLATE/dns.md b/.github/ISSUE_TEMPLATE/2dns.md similarity index 61% rename from .github/ISSUE_TEMPLATE/dns.md rename to .github/ISSUE_TEMPLATE/2dns.md index d0942c54..ac13523f 100644 --- a/.github/ISSUE_TEMPLATE/dns.md +++ b/.github/ISSUE_TEMPLATE/2dns.md @@ -1,12 +1,12 @@ --- name: DNS Provider Apply -about: 请求支持新的域名提供商 +about: 域名提供商申请支持 title: "[DNS] " labels: feature --- -> 感谢您支持certd,请按如下规范提交issue +> 感谢您支持certd,请按如下规范提交issue > 如果有条件,请尽量在[github上提交](https://github.com/certd/certd/issues) # 新域名提供商支持申请 @@ -14,23 +14,23 @@ labels: feature ## 1. 基本信息 请填写如下内容: -1. 域名提供商名称: +1. 域名提供商名称: 2. 管理页面地址: -3. 是否有API接口,接口地址: +3. 是否有API接口,接口地址: -4. 如果没有API接口,网页登录是否有验证码: +4. 如果没有API接口,网页登录是否有验证码: 5. 是否可以提供测试账号?(如果可以请留下联系方式或者加作者好友) -## 2. 截图 +## 2. 截图 `域名管理页面截图` diff --git a/.github/ISSUE_TEMPLATE/bug.md b/.github/ISSUE_TEMPLATE/3bug.md similarity index 86% rename from .github/ISSUE_TEMPLATE/bug.md rename to .github/ISSUE_TEMPLATE/3bug.md index 4cc6c94d..fbbf5b17 100644 --- a/.github/ISSUE_TEMPLATE/bug.md +++ b/.github/ISSUE_TEMPLATE/3bug.md @@ -1,12 +1,12 @@ --- name: Bug Report -about: 报告一个错误或问题 +about: 错误或问题报告 title: "[BUG] " labels: bug --- -> 感谢您支持certd,请按如下规范提交issue +> 感谢您支持certd,请按如下规范提交issue > 如果有条件,请尽量在[github上提交](https://github.com/certd/certd/issues) # bug提交 diff --git a/.github/ISSUE_TEMPLATE/feature.md b/.github/ISSUE_TEMPLATE/4feature.md similarity index 82% rename from .github/ISSUE_TEMPLATE/feature.md rename to .github/ISSUE_TEMPLATE/4feature.md index f39a1ddf..932cefeb 100644 --- a/.github/ISSUE_TEMPLATE/feature.md +++ b/.github/ISSUE_TEMPLATE/4feature.md @@ -1,11 +1,11 @@ --- name: Feature Request -about: 新需求、新特性 +about: 新需求、新特性申请支持 title: "[Feature] " labels: feature --- -> > 感谢您支持certd,请按如下规范提交issue +> > 感谢您支持certd,请按如下规范提交issue > 如果有条件,请尽量在[github上提交](https://github.com/certd/certd/issues) diff --git a/packages/plugins/plugin-lib/src/ssh/ssh.ts b/packages/plugins/plugin-lib/src/ssh/ssh.ts index e80079a4..d0aa74e3 100644 --- a/packages/plugins/plugin-lib/src/ssh/ssh.ts +++ b/packages/plugins/plugin-lib/src/ssh/ssh.ts @@ -247,6 +247,9 @@ export class AsyncSsh2Client { const err = this.convert(iconv, ret); stdErr += err; hasErrorLog = true; + if (err.includes("sudo: a password is required")) { + this.logger.warn("请配置sudo免密,否则命令无法执行"); + } this.logger.error(`[${this.connConf.host}][error]: ` + err.trimEnd()); }); });