From 2bee0399490ef8e41134726b033cfb4eb2ceb319 Mon Sep 17 00:00:00 2001 From: Javier Viola Date: Sat, 19 Oct 2024 19:25:35 -0300 Subject: [PATCH 1/3] set timeout for wait cmd --- .../packages/orchestrator/src/providers/k8s/kubeClient.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts b/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts index 831744960..349076468 100644 --- a/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts +++ b/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts @@ -232,7 +232,7 @@ export class KubeClient extends Client { await this.waitPodReady(name); if (longRunning) - await this.runCommand(["wait", "--for=condition=Ready", `Pod/${name}`]); + await this.runCommand(["wait", "--for=condition=Ready", "--timeout=240s", `Pod/${name}`]); logTable = new CreateLogTable({ colWidths: [20, 100], @@ -569,7 +569,7 @@ export class KubeClient extends Client { xinfra, }); debug("waiting for pod: fileserver, to be ready"); - await this.runCommand(["wait", "--for=condition=Ready", "Pod/fileserver"]); + await this.runCommand(["wait", "--for=condition=Ready", "--timeout=240s", "Pod/fileserver"]); await this.waitPodReady("fileserver"); debug("pod: fileserver, ready"); let fileServerOk = false; From bd1a88b59af58525cc62112de7d8104e8eaebd79 Mon Sep 17 00:00:00 2001 From: Javier Viola Date: Sat, 19 Oct 2024 19:28:32 -0300 Subject: [PATCH 2/3] lint --- .../orchestrator/src/providers/k8s/kubeClient.ts | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts b/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts index 349076468..dad98a3cd 100644 --- a/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts +++ b/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts @@ -232,7 +232,12 @@ export class KubeClient extends Client { await this.waitPodReady(name); if (longRunning) - await this.runCommand(["wait", "--for=condition=Ready", "--timeout=240s", `Pod/${name}`]); + await this.runCommand([ + "wait", + "--for=condition=Ready", + "--timeout=240s", + `Pod/${name}`, + ]); logTable = new CreateLogTable({ colWidths: [20, 100], @@ -569,7 +574,12 @@ export class KubeClient extends Client { xinfra, }); debug("waiting for pod: fileserver, to be ready"); - await this.runCommand(["wait", "--for=condition=Ready", "--timeout=240s", "Pod/fileserver"]); + await this.runCommand([ + "wait", + "--for=condition=Ready", + "--timeout=240s", + "Pod/fileserver", + ]); await this.waitPodReady("fileserver"); debug("pod: fileserver, ready"); let fileServerOk = false; From 3df0618c6231bef1fea94c39a56f60b377f39bf1 Mon Sep 17 00:00:00 2001 From: Javier Viola Date: Sun, 20 Oct 2024 07:08:25 -0300 Subject: [PATCH 3/3] inc to 300s --- .../packages/orchestrator/src/providers/k8s/kubeClient.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts b/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts index dad98a3cd..c0e7a34d6 100644 --- a/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts +++ b/javascript/packages/orchestrator/src/providers/k8s/kubeClient.ts @@ -235,7 +235,8 @@ export class KubeClient extends Client { await this.runCommand([ "wait", "--for=condition=Ready", - "--timeout=240s", + // wait for 5 mins in case we need to spin a new vm + "--timeout=300s", `Pod/${name}`, ]); @@ -577,7 +578,8 @@ export class KubeClient extends Client { await this.runCommand([ "wait", "--for=condition=Ready", - "--timeout=240s", + // wait for 5 mins in case we need to spin a new vm + "--timeout=300s", "Pod/fileserver", ]); await this.waitPodReady("fileserver");