chore: format

This commit is contained in:
xiaojunnuo
2026-05-31 01:41:33 +08:00
parent acd440106b
commit 4b57a0d729
557 changed files with 12530 additions and 14039 deletions
@@ -10,19 +10,18 @@ import { PageSearch } from "@certd/pipeline";
desc: "火山引擎DNS解析提供商",
accessType: "volcengine",
icon: "svg:icon-volcengine",
order:2,
order: 2,
})
export class VolcengineDnsProvider extends AbstractDnsProvider {
client: VolcengineDnsClient;
access!: VolcengineAccess;
async onInstance() {
this.access = this.ctx.access as VolcengineAccess
this.access = this.ctx.access as VolcengineAccess;
this.client = new VolcengineDnsClient({
access: this.access,
logger: this.logger,
http: this.http
http: this.http,
});
}
@@ -30,7 +29,7 @@ export class VolcengineDnsProvider extends AbstractDnsProvider {
* @param domain
*/
async getDomain(domain: string) {
const res = await this.client.findDomain(domain)
const res = await this.client.findDomain(domain);
if (res.Result.Zones && res.Result.Zones.length > 0) {
return res.Result.Zones[0];
@@ -38,7 +37,6 @@ export class VolcengineDnsProvider extends AbstractDnsProvider {
throw new Error(`域名${domain}不存在`);
}
async createRecord(options: CreateRecordOptions): Promise<any> {
const { fullRecord, hostRecord, value, type, domain } = options;
this.logger.info("添加域名解析:", fullRecord, value, domain);
@@ -48,9 +46,9 @@ export class VolcengineDnsProvider extends AbstractDnsProvider {
const body = {
ZID,
"Host": hostRecord,
"Type": type,
"Value": value
Host: hostRecord,
Type: type,
Value: value,
};
const res = await this.client.doRequest({
@@ -59,23 +57,22 @@ export class VolcengineDnsProvider extends AbstractDnsProvider {
region: "cn-beijing",
query: {
Action: "CreateRecord",
Version: "2018-08-01"
Version: "2018-08-01",
},
body
body,
});
return {
RecordID: res.Result.RecordID,
ZID: ZID
ZID: ZID,
};
}
async removeRecord(options: RemoveRecordOptions<any>): Promise<any> {
const record = options.recordRes;
const body = {
RecordID: record.RecordID
RecordID: record.RecordID,
};
await this.client.doRequest({
@@ -84,14 +81,14 @@ export class VolcengineDnsProvider extends AbstractDnsProvider {
region: "cn-beijing",
query: {
Action: "DeleteRecord",
Version: "2018-08-01"
Version: "2018-08-01",
},
body
body,
});
}
async getDomainListPage(page: PageSearch) {
return await this.client.getDomainList(page)
return await this.client.getDomainList(page);
}
}