Added dev reporting

This commit is contained in:
Dunemask 2022-07-07 21:45:38 +00:00
parent d4acc497f1
commit f559b653f2
10 changed files with 145 additions and 12 deletions

View file

@ -1,5 +1,6 @@
import { v4 } from "uuid";
import applyJob from "./kubernetes.js";
import buildJob from "./job-builder.js";
const maxJobs = process.env.MAX_JOBS ? parseInt(process.env.MAX_JOBS) : 3;
@ -41,7 +42,8 @@ class JobManager {
this.clientMaxJobs
)
throw Error("Client's Active Jobs Exceeded!");
const job = { ...jobRequest };
const job = buildJob(jobRequest, id);
job.id = v4();
job.log = [];
this.clients[id].jobs.push(job);