diff --git a/ci/dra_common.sh b/ci/dra_common.sh index d789237cb30..5e4d769d630 100755 --- a/ci/dra_common.sh +++ b/ci/dra_common.sh @@ -11,7 +11,11 @@ function save_docker_tarballs { local arch="${1:?architecture required}" local version="${2:?stack-version required}" for image in logstash logstash-oss logstash-ubi8; do - docker save "docker.elastic.co/logstash/${image}:${version}" | gzip -c > "build/${image}-${version}-docker-image-${arch}.tar.gz" + docker save -o "build/${image}-${version}-docker-image-${arch}.tar" \ + "docker.elastic.co/logstash/${image}:${version}" || \ + error "Hit a problem in saving the Docker image for ${image}" + # NOTE: if docker save exited with non-zero the error log already exited the script + gzip "build/${image}-${version}-docker-image-${arch}.tar" done }