mirror of
https://github.com/whyour/qinglong.git
synced 2026-07-01 04:40:38 +08:00
修复运行命令api任务日志路径
This commit is contained in:
@@ -177,11 +177,17 @@ export default class SystemService {
|
||||
}
|
||||
}
|
||||
|
||||
public async run({ command }: { command: string }, callback: TaskCallbacks) {
|
||||
public async run(
|
||||
{ command, logPath }: { command: string; logPath: string },
|
||||
callback: TaskCallbacks,
|
||||
) {
|
||||
if (!command.startsWith(TASK_COMMAND)) {
|
||||
command = `${TASK_COMMAND} ${command}`;
|
||||
}
|
||||
this.scheduleService.runTask(`real_time=true ${command}`, callback);
|
||||
this.scheduleService.runTask(
|
||||
`real_log_path=${logPath} real_time=true ${command}`,
|
||||
callback,
|
||||
);
|
||||
}
|
||||
|
||||
public async stop({ command }: { command: string }) {
|
||||
|
||||
Reference in New Issue
Block a user