mirror of https://github.com/certd/certd
perf: 支持plesk网站证书部署
parent
53c38cf714
commit
eda45c1528
|
@ -37,6 +37,8 @@ function buildGroupOptions(options: any[], inDomains: string[]) {
|
|||
}
|
||||
|
||||
export const optionsUtils = {
|
||||
//获取分组
|
||||
groupByDomain,
|
||||
//构建分组后的选项列表,常用
|
||||
buildGroupOptions,
|
||||
};
|
||||
|
|
|
@ -156,13 +156,13 @@ export function createAxiosService({ logger }: { logger: Logger }) {
|
|||
error.message = '请求错误';
|
||||
break;
|
||||
case 401:
|
||||
error.message = '未授权,请登录';
|
||||
error.message = '认证/登录失败';
|
||||
break;
|
||||
case 403:
|
||||
error.message = '拒绝访问';
|
||||
break;
|
||||
case 404:
|
||||
error.message = `请求地址出错: ${error.response.config.url}`;
|
||||
error.message = `请求地址出错`;
|
||||
break;
|
||||
case 408:
|
||||
error.message = '请求超时';
|
||||
|
@ -216,6 +216,7 @@ export type HttpRequestConfig<D = any> = {
|
|||
logParams?: boolean;
|
||||
logRes?: boolean;
|
||||
httpProxy?: string;
|
||||
returnResponse?: boolean;
|
||||
} & AxiosRequestConfig<D>;
|
||||
export type HttpClient = {
|
||||
request<D = any, R = any>(config: HttpRequestConfig<D>): Promise<HttpClientResponse<R>>;
|
||||
|
|
|
@ -385,7 +385,7 @@ export class Executor {
|
|||
content = `流水线ID:${this.pipeline.id},运行ID:${this.runtime.id}`;
|
||||
} else if (when === "error") {
|
||||
subject = `执行失败,${this.pipeline.title}【${this.pipeline.id}】`;
|
||||
content = `流水线ID:${this.pipeline.id},运行ID:${this.runtime.id}\n错误详情:${error.message}`;
|
||||
content = `流水线ID:${this.pipeline.id},运行ID:${this.runtime.id}\n\n${this.currentStatusMap?.currentStep?.title} 执行失败\n\n错误详情:${error.message}`;
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -134,6 +134,7 @@ export class RunHistory {
|
|||
export class RunnableCollection {
|
||||
private collection: RunnableMap = {};
|
||||
private pipeline!: Pipeline;
|
||||
currentStep!: Step;
|
||||
constructor(pipeline?: Pipeline) {
|
||||
if (!pipeline) {
|
||||
return;
|
||||
|
@ -193,5 +194,8 @@ export class RunnableCollection {
|
|||
|
||||
add(runnable: Runnable) {
|
||||
this.collection[runnable.id] = runnable;
|
||||
if (runnable.runnableType === "step") {
|
||||
this.currentStep = runnable as Step;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue