From da796ef03ac3f5c7a976176f51c753bb6536c548 Mon Sep 17 00:00:00 2001 From: Dan Callaghan Date: Jul 04 2018 06:22:20 +0000 Subject: Jenkinsfile: retry pushes to internal registry, to work around "unknown blob" Commit 3ef1f4b2 added a retry in one of two places where we push to the registry. This adds a retry in the other. --- diff --git a/Jenkinsfile b/Jenkinsfile index b20be47..c24730f 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -139,7 +139,12 @@ node('docker') { * Dockerfile used, which will break if the build directory (here ".") * is not the final argument in the string. */ def image = docker.build "factory2/waiverdb:internal-${appversion}", "--build-arg waiverdb_rpm=$f28_rpm --build-arg waiverdb_common_rpm=$waiverdb_common --build-arg cacert_url=https://password.corp.redhat.com/RH-IT-Root-CA.crt ." - image.push() + /* Pushes to the internal registry can sometimes randomly fail + * with "unknown blob" due to a known issue with the registry + * storage configuration. So we retry up to 3 times. */ + retry(3) { + image.push() + } } docker.withRegistry( 'https://quay.io/',