mirror of
https://github.com/certd/certd.git
synced 2026-04-24 20:57:26 +08:00
chore: 1
This commit is contained in:
@@ -22,7 +22,7 @@ export class SshClient {
|
|||||||
uploadFiles(options: { connectConf: ConnectConfig; transports: any }) {
|
uploadFiles(options: { connectConf: ConnectConfig; transports: any }) {
|
||||||
const { connectConf, transports } = options;
|
const { connectConf, transports } = options;
|
||||||
const conn = new ssh2.Client();
|
const conn = new ssh2.Client();
|
||||||
|
this.logger.info('开始连接服务器');
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
conn
|
conn
|
||||||
.on('ready', () => {
|
.on('ready', () => {
|
||||||
|
|||||||
@@ -111,7 +111,7 @@ export class UploadCertToHostPlugin extends AbstractTaskPlugin {
|
|||||||
if (!accessId) {
|
if (!accessId) {
|
||||||
throw new Error('主机登录授权配置不能为空');
|
throw new Error('主机登录授权配置不能为空');
|
||||||
}
|
}
|
||||||
this.logger.info('开始连接服务器');
|
this.logger.info('准备上传到服务器');
|
||||||
const connectConf = await this.accessService.getById(accessId);
|
const connectConf = await this.accessService.getById(accessId);
|
||||||
const sshClient = new SshClient(this.logger);
|
const sshClient = new SshClient(this.logger);
|
||||||
await sshClient.uploadFiles({
|
await sshClient.uploadFiles({
|
||||||
|
|||||||
Reference in New Issue
Block a user