From ce9fddec5948700a160d43779a11d90c37fcc3db Mon Sep 17 00:00:00 2001 From: Vanessa Stoiber <52395160+dvvanessastoiber@users.noreply.github.com> Date: Wed, 8 May 2024 14:06:30 +0200 Subject: [PATCH] init podData --- src/org/ods/orchestration/phases/DeployOdsComponent.groovy | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/org/ods/orchestration/phases/DeployOdsComponent.groovy b/src/org/ods/orchestration/phases/DeployOdsComponent.groovy index 2244026c1..89eac0d8d 100644 --- a/src/org/ods/orchestration/phases/DeployOdsComponent.groovy +++ b/src/org/ods/orchestration/phases/DeployOdsComponent.groovy @@ -59,15 +59,17 @@ class DeployOdsComponent { applyTemplates(openShiftDir, deploymentMean) def retries = project.environmentConfig?.openshiftRolloutTimeoutRetries ?: 10 + def podData = [] for (def i = 0; i < retries; i++) { - def podData = os.checkForPodData(project.targetProject, deploymentMean.selector) + podData = os.checkForPodData(project.targetProject, deploymentMean.selector) if (podData) { return podData } steps.echo("Could not find 'running' pod(s) with label '${deploymentMean.selector}' - waiting") steps.sleep(12) - } + } + // TODO: What if podData is empty? // TODO: Once the orchestration pipeline can deal with multiple replicas, // update this to deal with multiple pods. def pod = podData[0].toMap()