From 0cdb25728e03a7ee844f4c0d98a805cf095342fa Mon Sep 17 00:00:00 2001 From: "mergify[bot]" <37929162+mergify[bot]@users.noreply.github.com> Date: Wed, 12 Jan 2022 11:55:38 +0100 Subject: [PATCH] chore: add resiliency when provisioning the stack (#1990) (#1993) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit 54e882b6d9bf3eccabbb845b1acbca7fc2d66d40) Co-authored-by: Manuel de la Peña --- .ci/Jenkinsfile | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.ci/Jenkinsfile b/.ci/Jenkinsfile index d21faa468d..23e93c6af3 100644 --- a/.ci/Jenkinsfile +++ b/.ci/Jenkinsfile @@ -209,9 +209,13 @@ pipeline { // Must be gathered after deployment as the public IP is known at that time def stackRunner = getNodeIp(stackWorkspace, 'stack') - ansible(stackWorkspace, - env.RUN_ID.split('-')[0], - "-i \"${stackRunner.ip},\" -t setup-stack --extra-vars=\"nodeLabel=stack nodeImage=${stackMachine.image} nodeInstanceType=${stackMachine.instance_type}\"") + retryWithSleep(retries: 2, seconds: 5, backoff: true) { + ansible( + stackWorkspace, + env.RUN_ID.split('-')[0], + "-i \"${stackRunner.ip},\" -t setup-stack --extra-vars=\"nodeLabel=stack nodeImage=${stackMachine.image} nodeInstanceType=${stackMachine.instance_type}\"" + ) + } // Update stash with latest changes from the stack deployment stash allowEmpty: true, name: 'sourceEnvModified', useDefaultExcludes: false