cleanup
parent
0dca08e2b6
commit
20a967df3b
|
|
@ -2888,13 +2888,11 @@ class Kubernetes {
|
|||
this.secretName = `build-credentials-${buildGuid}`;
|
||||
this.jobName = `unity-builder-job-${buildGuid}`;
|
||||
this.containerName = `main`;
|
||||
cloud_runner_logger_1.default.log(`Creating build Secret ${JSON.stringify(this.secretName, undefined, 4)}`);
|
||||
yield kubernetes_secret_1.default.createSecret(secrets, this.secretName, this.namespace, this.kubeClient);
|
||||
const jobSpec = kubernetes_job_spec_factory_1.default.getJobSpec(commands, image, mountdir, workingdir, environment, secrets, this.buildGuid, this.buildParameters, this.secretName, this.pvcName, this.jobName, k8s);
|
||||
cloud_runner_logger_1.default.log(`Creating build job ${JSON.stringify(jobSpec, undefined, 4)}`);
|
||||
// Run
|
||||
cloud_runner_logger_1.default.log(`Build job secret created ${JSON.stringify(this.secretName, undefined, 4)}`);
|
||||
const jobResult = yield this.kubeClientBatch.createNamespacedJob(this.namespace, jobSpec);
|
||||
cloud_runner_logger_1.default.log(`Created build job ${JSON.stringify(jobResult.body.metadata, undefined, 4)}`);
|
||||
cloud_runner_logger_1.default.log(`Build job created ${JSON.stringify(jobResult.body.metadata, undefined, 4)}`);
|
||||
yield new Promise((promise) => setTimeout(promise, 5000));
|
||||
cloud_runner_logger_1.default.log('Job created');
|
||||
this.setPodNameAndContainerName(yield Kubernetes.findPodFromJob(this.kubeClient, this.jobName, this.namespace));
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -99,7 +99,6 @@ class Kubernetes implements ProviderInterface {
|
|||
this.secretName = `build-credentials-${buildGuid}`;
|
||||
this.jobName = `unity-builder-job-${buildGuid}`;
|
||||
this.containerName = `main`;
|
||||
CloudRunnerLogger.log(`Creating build Secret ${JSON.stringify(this.secretName, undefined, 4)}`);
|
||||
await KubernetesSecret.createSecret(secrets, this.secretName, this.namespace, this.kubeClient);
|
||||
const jobSpec = KubernetesJobSpecFactory.getJobSpec(
|
||||
commands,
|
||||
|
|
@ -115,11 +114,10 @@ class Kubernetes implements ProviderInterface {
|
|||
this.jobName,
|
||||
k8s,
|
||||
);
|
||||
CloudRunnerLogger.log(`Creating build job ${JSON.stringify(jobSpec, undefined, 4)}`);
|
||||
CloudRunnerLogger.log(`Build job secret created ${JSON.stringify(this.secretName, undefined, 4)}`);
|
||||
|
||||
// Run
|
||||
const jobResult = await this.kubeClientBatch.createNamespacedJob(this.namespace, jobSpec);
|
||||
CloudRunnerLogger.log(`Created build job ${JSON.stringify(jobResult.body.metadata, undefined, 4)}`);
|
||||
CloudRunnerLogger.log(`Build job created ${JSON.stringify(jobResult.body.metadata, undefined, 4)}`);
|
||||
|
||||
await new Promise((promise) => setTimeout(promise, 5000));
|
||||
CloudRunnerLogger.log('Job created');
|
||||
|
|
|
|||
Loading…
Reference in New Issue