Updated Core
This commit is contained in:
parent
8b136eb565
commit
88ebfe4da2
25 changed files with 5678 additions and 1932 deletions
16
lib/core/internal-deploy.js
Normal file
16
lib/core/internal-deploy.js
Normal file
|
@ -0,0 +1,16 @@
|
|||
import { INFO, ERR, OK, VERB } from "../util/logging.js";
|
||||
import Executor from "../sockets/clients/Executor.js";
|
||||
import cp from "node:child_process";
|
||||
|
||||
const jobStr = process.argv.slice(2)[0];
|
||||
const job = JSON.parse(jobStr);
|
||||
const { command } = job.spec.template.spec.containers[0];
|
||||
INFO("EXEC", "Internal Executor Starting!");
|
||||
cp.exec(command, (error, stdout, stderr)=>{
|
||||
if(error) ERR("EXEC", error);
|
||||
//if(stdout) VERB("EXEC-STDOUT", stdout);
|
||||
//if(stderr) VERB("EXEC-STDERR", stderr);
|
||||
OK("EXEC", "Internal Executor Finished!");
|
||||
process.exit(error? 1 : 0 );
|
||||
});
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue