totvs-dtsenv-cli
Version:
TOTVS Datasul Environment Command Line
27 lines (18 loc) • 642 B
text/typescript
import * as program from "commander";
import * as fs from "fs";
import CommandUtils from "../utils/CommandUtils";
export default class StartCommand {
static program : any
constructor(commander: any) {
commander.command('start')
.description('Inicia o ambiente Datasul configurado.')
.action(StartCommand.actionCommand)
StartCommand.program = commander;
}
static actionCommand() {
console.log("Iniciando o ambiente...")
/** Iniciando ambiente de gerenciamento */
let cmd = CommandUtils.execCommandSync('docker-compose', ['start'])
console.log("Ambiente iniciado com sucesso.")
}
}