mirror of
https://github.com/certd/certd.git
synced 2026-04-23 11:37:23 +08:00
pref: 日志中加密授权信息输出替换成星号
This commit is contained in:
+1
-1
@@ -79,7 +79,7 @@ export class TencentDeleteExpiringCert extends AbstractPlusTaskPlugin {
|
||||
async onInstance() {}
|
||||
|
||||
async execute(): Promise<void> {
|
||||
const access = await this.accessService.getById<TencentAccess>(this.accessId);
|
||||
const access = await this.getAccess<TencentAccess>(this.accessId);
|
||||
const sslClient = new TencentSslClient({
|
||||
access,
|
||||
logger: this.logger,
|
||||
|
||||
@@ -53,7 +53,7 @@ export class DeployCertToTencentAll extends AbstractTaskPlugin {
|
||||
|
||||
async onInstance() {}
|
||||
async execute(): Promise<void> {
|
||||
const accessProvider = await this.accessService.getById(this.accessId);
|
||||
const accessProvider = await this.getAccess(this.accessId);
|
||||
|
||||
const sdk = await import('tencentcloud-sdk-nodejs/tencentcloud/services/ssl/v20191205/index.js');
|
||||
const Client = sdk.v20191205.Client;
|
||||
|
||||
+2
-2
@@ -51,7 +51,7 @@ export class TencentDeployCertToCDNv2 extends AbstractTaskPlugin {
|
||||
async onInstance() {}
|
||||
|
||||
async execute(): Promise<void> {
|
||||
const access = await this.accessService.getById<TencentAccess>(this.accessId);
|
||||
const access = await this.getAccess<TencentAccess>(this.accessId);
|
||||
const sslClient = new TencentSslClient({
|
||||
access,
|
||||
logger: this.logger,
|
||||
@@ -82,7 +82,7 @@ export class TencentDeployCertToCDNv2 extends AbstractTaskPlugin {
|
||||
}
|
||||
|
||||
async getCdnClient() {
|
||||
const accessProvider = await this.accessService.getById<TencentAccess>(this.accessId);
|
||||
const accessProvider = await this.getAccess<TencentAccess>(this.accessId);
|
||||
const sdk = await import('tencentcloud-sdk-nodejs/tencentcloud/services/cdn/v20180606/index.js');
|
||||
const CdnClient = sdk.v20180606.Client;
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ export class DeployToCdnPlugin extends AbstractTaskPlugin {
|
||||
}
|
||||
|
||||
async getClient() {
|
||||
const accessProvider: TencentAccess = (await this.accessService.getById(this.accessId)) as TencentAccess;
|
||||
const accessProvider: TencentAccess = (await this.getAccess(this.accessId)) as TencentAccess;
|
||||
|
||||
const CdnClient = this.Client;
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@ export class DeployCertToTencentCLB extends AbstractTaskPlugin {
|
||||
const sdk = await import('tencentcloud-sdk-nodejs/tencentcloud/services/clb/v20180317/index.js');
|
||||
const ClbClient = sdk.v20180317.Client;
|
||||
|
||||
const accessProvider = (await this.accessService.getById(this.accessId)) as TencentAccess;
|
||||
const accessProvider = (await this.getAccess(this.accessId)) as TencentAccess;
|
||||
|
||||
const region = this.region;
|
||||
const clientConfig = {
|
||||
|
||||
@@ -99,7 +99,7 @@ export class DeployCertToTencentCosPlugin extends AbstractTaskPlugin {
|
||||
async onInstance() {}
|
||||
|
||||
async execute(): Promise<void> {
|
||||
const access = await this.accessService.getById(this.accessId);
|
||||
const access = await this.getAccess(this.accessId);
|
||||
|
||||
const client = new TencentSslClient({
|
||||
access,
|
||||
@@ -130,7 +130,7 @@ export class DeployCertToTencentCosPlugin extends AbstractTaskPlugin {
|
||||
}
|
||||
|
||||
async onGetDomainList(data: any) {
|
||||
const access = await this.accessService.getById(this.accessId);
|
||||
const access = await this.getAccess(this.accessId);
|
||||
|
||||
const cosv5 = await import('cos-nodejs-sdk-v5');
|
||||
const cos = new cosv5.default({
|
||||
|
||||
@@ -80,7 +80,7 @@ export class DeployCertToTencentEO extends AbstractTaskPlugin {
|
||||
}
|
||||
|
||||
async execute(): Promise<void> {
|
||||
const accessProvider: TencentAccess = (await this.accessService.getById(this.accessId)) as TencentAccess;
|
||||
const accessProvider: TencentAccess = (await this.getAccess(this.accessId)) as TencentAccess;
|
||||
const client = this.getClient(accessProvider);
|
||||
const params = this.buildParams();
|
||||
await this.doRequest(client, params);
|
||||
|
||||
@@ -52,7 +52,7 @@ export class TencentDeployCertToLive extends AbstractPlusTaskPlugin {
|
||||
async onInstance() {}
|
||||
|
||||
async execute(): Promise<void> {
|
||||
const access = await this.accessService.getById<TencentAccess>(this.accessId);
|
||||
const access = await this.getAccess<TencentAccess>(this.accessId);
|
||||
|
||||
let tencentCertId = this.cert as string;
|
||||
if (typeof this.cert !== 'string') {
|
||||
@@ -90,7 +90,7 @@ export class TencentDeployCertToLive extends AbstractPlusTaskPlugin {
|
||||
}
|
||||
|
||||
async getLiveClient() {
|
||||
const accessProvider = await this.accessService.getById<TencentAccess>(this.accessId);
|
||||
const accessProvider = await this.getAccess<TencentAccess>(this.accessId);
|
||||
const sdk = await import('tencentcloud-sdk-nodejs/tencentcloud/services/live/v20180801/index.js');
|
||||
const CssClient = sdk.v20180801.Client;
|
||||
|
||||
|
||||
+1
-1
@@ -116,7 +116,7 @@ export class DeployCertToTencentTKEIngressPlugin extends AbstractPlusTaskPlugin
|
||||
this.K8sClient = k8sSdk.K8sClient;
|
||||
}
|
||||
async execute(): Promise<void> {
|
||||
const accessProvider = await this.accessService.getById(this.accessId);
|
||||
const accessProvider = await this.getAccess(this.accessId);
|
||||
const tkeClient = await this.getTkeClient(accessProvider, this.region);
|
||||
const kubeConfigStr = await this.getTkeKubeConfig(tkeClient, this.clusterId);
|
||||
|
||||
|
||||
@@ -135,7 +135,7 @@ export class TencentActionInstancesPlugin extends AbstractTaskPlugin {
|
||||
}
|
||||
|
||||
async getCvmClient() {
|
||||
const accessProvider = await this.accessService.getById<TencentAccess>(this.accessId);
|
||||
const accessProvider = await this.getAccess<TencentAccess>(this.accessId);
|
||||
const sdk = await import('tencentcloud-sdk-nodejs/tencentcloud/services/cvm/v20170312/index.js');
|
||||
const CvmClient = sdk.v20170312.Client;
|
||||
|
||||
|
||||
+2
-2
@@ -52,7 +52,7 @@ export class UploadCertToTencent extends AbstractTaskPlugin {
|
||||
|
||||
async execute(): Promise<void> {
|
||||
const { accessId, name, cert } = this;
|
||||
const accessProvider = await this.accessService.getById(accessId);
|
||||
const accessProvider = await this.getAccess(accessId);
|
||||
const certName = this.appendTimeSuffix(name || cert.domain);
|
||||
const client = this.getClient(accessProvider);
|
||||
|
||||
@@ -96,7 +96,7 @@ export class UploadCertToTencent extends AbstractTaskPlugin {
|
||||
|
||||
// async rollback({ input }) {
|
||||
// const { accessId } = input;
|
||||
// const accessProvider = await this.accessService.getById(accessId);
|
||||
// const accessProvider = await this.getAccess(accessId);
|
||||
// const client = this.getClient(accessProvider);
|
||||
//
|
||||
// const { tencentCertId } = context;
|
||||
|
||||
Reference in New Issue
Block a user