aws/k8s smoke test

pull/496/head
Frostebite 2023-02-16 00:09:32 +00:00
parent 77bcf7975c
commit a45f79e918
3 changed files with 5 additions and 4 deletions

3
dist/index.js generated vendored
View File

@ -4018,6 +4018,7 @@ const async_wait_until_1 = __importDefault(__nccwpck_require__(41299));
const follow_log_stream_service_1 = __nccwpck_require__(64121);
class KubernetesTaskRunner {
static runTask(kubeConfig, kubeClient, jobName, podName, containerName, namespace, alreadyFinished = false) {
var _a;
return __awaiter(this, void 0, void 0, function* () {
cloud_runner_logger_1.default.log(`Streaming logs from pod: ${podName} container: ${containerName} namespace: ${namespace}`);
const stream = new stream_1.Writable();
@ -4102,7 +4103,7 @@ class KubernetesTaskRunner {
stream.destroy();
}
cloud_runner_logger_1.default.log('k8s task runner failed');
cloud_runner_logger_1.default.log(JSON.stringify(error, undefined, 4));
cloud_runner_logger_1.default.log(JSON.stringify(((_a = error === null || error === void 0 ? void 0 : error.response) === null || _a === void 0 ? void 0 : _a.body) || error, undefined, 4));
}
cloud_runner_logger_1.default.log('end of log stream');
return output;

2
dist/index.js.map generated vendored

File diff suppressed because one or more lines are too long

View File

@ -107,12 +107,12 @@ class KubernetesTaskRunner {
);
throw new Error(`No logs streamed from k8s`);
}
} catch (error) {
} catch (error: any) {
if (stream) {
stream.destroy();
}
CloudRunnerLogger.log('k8s task runner failed');
CloudRunnerLogger.log(JSON.stringify(error, undefined, 4));
CloudRunnerLogger.log(JSON.stringify(error?.response?.body || error, undefined, 4));
}
CloudRunnerLogger.log('end of log stream');