diff --git a/.ci/packaging.groovy b/.ci/packaging.groovy index 5e6d6558f67..290c9bba601 100644 --- a/.ci/packaging.groovy +++ b/.ci/packaging.groovy @@ -215,12 +215,12 @@ def tagAndPush(name){ docker push ${newName} docker tag ${oldName} ${commitName} docker push ${commitName} - """, returnStatus: true) - if ( status > 0 && iterations < 3) { - error('tag and push failed, retry') - } else if ( status > 0 ) { - log(level: 'WARN', text: "${name} doesn't have ${variant} docker images. See https://github.com/elastic/beats/pull/21621") - } + """, returnStatus: true) + + if ( status > 0 && iterations < 3) { + error('tag and push failed, retry') + } else if ( status > 0 ) { + log(level: 'WARN', text: "${name} doesn't have ${variant} docker images. See https://github.com/elastic/beats/pull/21621") } } }