fix: 修复上传到cos报runtimeDepsService未初始化的问题

This commit is contained in:
xiaojunnuo
2026-07-15 01:09:57 +08:00
parent b91c9e4ea6
commit 167b303fae
53 changed files with 517 additions and 1533 deletions
@@ -1,4 +1,4 @@
import { ILogger, utils } from "@certd/basic";
import { ILogger, utils } from "@certd/basic";
import { AliyunAccess } from "../access/index.js";
import { AliyunClient } from "./index.js";
import { CertInfo, CertReader, SimpleCertDetail } from "@certd/plugin-lib";
@@ -12,6 +12,7 @@ export type AliyunSslClientOpts = {
logger: ILogger;
endpoint?: string;
region?: string;
};
export type AliyunSslGetResourceListReq = {
@@ -42,9 +43,11 @@ export type CasCertId = {
export class AliyunSslClient {
opts: AliyunSslClientOpts;
logger: ILogger;
constructor(opts: AliyunSslClientOpts) {
this.opts = opts;
this.logger = opts.logger;
}
checkRet(ret: any) {
@@ -55,7 +58,7 @@ export class AliyunSslClient {
async getClient() {
const access = this.opts.access;
const client = new AliyunClient({ logger: this.opts.logger, importRuntime: access.importRuntime.bind(access) });
const client = new AliyunClient({ logger: this.opts.logger });
let endpoint = this.opts.endpoint || "cas.aliyuncs.com";
if (this.opts.endpoint == null && this.opts.region) {
@@ -251,3 +254,5 @@ export class AliyunSslClient {
}
}
}