mirror of
https://github.com/certd/certd.git
synced 2026-05-14 03:57:30 +08:00
perf: 增加权威NS检查开关,某些用户服务器禁止向黑名单NS服务器发请求
This commit is contained in:
@@ -749,6 +749,18 @@ export default {
|
||||
pipelineValidTimeEnabledHelper: "Whether to enable the valid time of the pipeline",
|
||||
certDomainAddToMonitorEnabled: "Add Domain to Certificate Monitor",
|
||||
certDomainAddToMonitorEnabledHelper: "Whether to add the domain to the certificate monitor",
|
||||
|
||||
defaultCertRenewDays: "Default Certificate Renew Days",
|
||||
defaultCertRenewDaysHelper: "Default certificate renewal days, helpful for table list progress bar display",
|
||||
defaultCertRenewDaysRecommend: "Recommend 15",
|
||||
|
||||
pipelineMaxRunningCount: "Max Running Count",
|
||||
pipelineMaxRunningCountHelper: "Max running count of the pipeline",
|
||||
pipelineMaxRunningCountRecommend: "Recommend 5-15, default 10",
|
||||
|
||||
acmeWalkFromAuthoritative: "Check TXT Record from Authoritative NS",
|
||||
acmeWalkFromAuthoritativeHelper: "Apply certificate when whether to check the TXT record from authoritative NS server first",
|
||||
|
||||
fixedCertExpireDays: "Fixed Cert Expire Days",
|
||||
fixedCertExpireDaysHelper: "Fixed cert expiration days, helpful for table list progress bar display",
|
||||
fixedCertExpireDaysRecommend: "Recommend 90",
|
||||
|
||||
@@ -760,6 +760,8 @@ export default {
|
||||
pipelineMaxRunningCount: "同时最大运行流水线数量",
|
||||
pipelineMaxRunningCountHelper: "同一个用户同时运行的最大流水线数量,避免同时触发太多导致ACME账户被限制",
|
||||
pipelineMaxRunningCountRecommend: "推荐5-15,默认10",
|
||||
acmeWalkFromAuthoritative: "从权威NS检查TXT记录",
|
||||
acmeWalkFromAuthoritativeHelper: "申请证书时,是否从权威NS服务器检查TXT记录,如果影响申请证书,可以关闭",
|
||||
|
||||
fixedCertExpireDays: "固定证书有效期天数",
|
||||
fixedCertExpireDaysHelper: "固定证书有效期天数,有助于列表进度条整齐显示",
|
||||
@@ -807,6 +809,7 @@ export default {
|
||||
environmentVars: "环境变量",
|
||||
environmentVarsHelper: "配置运行时环境变量,每行一个,格式:KEY=VALUE",
|
||||
bindUrl: "绑定URL",
|
||||
bindUrlHelper: "绑定URL,在各类通知中显示你的站点URL",
|
||||
},
|
||||
},
|
||||
modal: {
|
||||
|
||||
@@ -109,6 +109,7 @@ export type SysPrivateSetting = {
|
||||
type?: string;
|
||||
config?: any;
|
||||
};
|
||||
acmeWalkFromAuthoritative?: boolean;
|
||||
|
||||
//http请求超时时间
|
||||
httpRequestTimeout?: number;
|
||||
|
||||
@@ -303,8 +303,18 @@ export const useSettingStore = defineStore({
|
||||
}
|
||||
};
|
||||
const { closable = false } = opts;
|
||||
let title = "URL地址未绑定,是否绑定此地址?";
|
||||
let okButtonText = "不,回到原来的地址";
|
||||
let okButtonDanger = false;
|
||||
let forceBack = true;
|
||||
if (closable) {
|
||||
title = "绑定URL";
|
||||
okButtonText = "确定";
|
||||
okButtonDanger = false;
|
||||
forceBack = false;
|
||||
}
|
||||
const modalRef: any = Modal.warning({
|
||||
title: "URL地址未绑定,是否绑定此地址?",
|
||||
title: title,
|
||||
width: 500,
|
||||
keyboard: false,
|
||||
closable,
|
||||
@@ -320,6 +330,7 @@ export const useSettingStore = defineStore({
|
||||
绑定到地址1
|
||||
</a-button>
|
||||
</div>
|
||||
<div class="helper">各类通知里面会以地址1作为URL显示</div>
|
||||
<div class="flex items-center justify-between mt-3">
|
||||
<span>
|
||||
绑定地址2:
|
||||
@@ -334,12 +345,14 @@ export const useSettingStore = defineStore({
|
||||
},
|
||||
onOk: async () => {
|
||||
// await this.doBindUrl();
|
||||
window.location.href = bindUrl;
|
||||
if (forceBack) {
|
||||
window.location.href = bindUrl;
|
||||
}
|
||||
},
|
||||
okButtonProps: {
|
||||
danger: true,
|
||||
danger: okButtonDanger,
|
||||
},
|
||||
okText: "不,回到原来的地址",
|
||||
okText: okButtonText,
|
||||
// cancelText: "不,回到原来的地址",
|
||||
// onOk: () => {
|
||||
// window.location.href = bindUrl;
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
|
||||
<a-form-item :label="t('certd.sys.setting.bindUrl')">
|
||||
<a-button class="ml-2" type="primary" @click="settingsStore.openBindUrlModal({ closable: true })">{{ t("certd.sys.setting.bindUrl") }}</a-button>
|
||||
<div class="helper" v-html="t('certd.sys.setting.bindUrlHelper')"></div>
|
||||
</a-form-item>
|
||||
|
||||
<a-form-item label=" " :colon="false" :wrapper-col="{ span: 8 }">
|
||||
|
||||
@@ -53,6 +53,13 @@
|
||||
<div class="helper">{{ t("certd.sys.setting.pipelineMaxRunningCountHelper") }}</div>
|
||||
</a-form-item>
|
||||
|
||||
<a-form-item :label="t('certd.sys.setting.acmeWalkFromAuthoritative')" :name="['private', 'acmeWalkFromAuthoritative']">
|
||||
<div class="flex items-center">
|
||||
<a-switch v-model:checked="formState.private.acmeWalkFromAuthoritative" />
|
||||
</div>
|
||||
<div class="helper">{{ t("certd.sys.setting.acmeWalkFromAuthoritativeHelper") }}</div>
|
||||
</a-form-item>
|
||||
|
||||
<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-form-item>
|
||||
@@ -76,7 +83,9 @@ defineOptions({
|
||||
|
||||
const formState = reactive<Partial<SysSettings>>({
|
||||
public: {},
|
||||
private: {},
|
||||
private: {
|
||||
acmeWalkFromAuthoritative: true,
|
||||
},
|
||||
});
|
||||
|
||||
async function loadSysSettings() {
|
||||
|
||||
Reference in New Issue
Block a user