Include log chunk when task runner sees log update, clarify if we can pull logs from same line or next line

This commit is contained in:
Frostebite 2023-09-24 14:57:44 +01:00
parent a760ee803f
commit 5631a3b301
3 changed files with 4 additions and 1 deletions

BIN
dist/index.js generated vendored

Binary file not shown.

BIN
dist/index.js.map generated vendored

Binary file not shown.

View File

@ -48,7 +48,10 @@ class KubernetesTaskRunner {
}
if (chunk.includes(`LOGS:`)) {
const result = RemoteClientLogger.HandleLogChunkLine(chunk);
CloudRunnerLogger.log(`Logs found HandleLogChunkLineResult:${result}\n${chunk}`);
// remove "LOGS: " and decode base64 remaining
const unpacked = Buffer.from(chunk.split(`LOGS: `)[1], 'base64').toString('ascii');
CloudRunnerLogger.log(`Logs found HandleLogChunkLineResult:${result}\n${unpacked}`);
}
}
};