diff --git a/ci-automation/ci-config.env b/ci-automation/ci-config.env index d061a9bf8f..2b3289283b 100644 --- a/ci-automation/ci-config.env +++ b/ci-automation/ci-config.env @@ -45,7 +45,7 @@ CONTAINER_IMAGE_ROOT="/home/sdk/build/images" # -- QEMU -- -QEMU_IMAGE_NAME="flatcar_production_image.bin" +QEMU_IMAGE_NAME=${QEMU_IMAGE_NAME:-flatcar_production_image.bin} QEMU_PARALLEL="${PARALLEL_TESTS:-20}" # BIOS path within the SDK diff --git a/ci-automation/test.sh b/ci-automation/test.sh index 18b2ffdacd..9162aecfaf 100644 --- a/ci-automation/test.sh +++ b/ci-automation/test.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/bash -x # # Copyright (c) 2021 The Flatcar Maintainers. # Use of this source code is governed by a BSD-style license that can be @@ -120,6 +120,7 @@ function _test_run_impl() { fi local retries="${MAX_RETRIES:-20}" + local skip_copy_to_bincache=${SKIP_COPY_TO_BINCACHE:-0} source ci-automation/tapfile_helper_lib.sh source ci-automation/ci_automation_common.sh @@ -216,14 +217,19 @@ function _test_run_impl() { echo "########### All re-runs exhausted ($retries). Giving up. ###########" fi - # publish kola output, TAP files to build cache - copy_to_buildcache "testing/${vernum}/${arch}/${image}" \ - "${tests_dir}/_kola_temp" - copy_to_buildcache "testing/${vernum}/${arch}/${image}" \ - "${tests_dir}/"*.tap - copy_to_buildcache "testing/${vernum}/${arch}/${image}" \ - "${tap_merged_summary}" - copy_to_buildcache "testing/${vernum}/${arch}/${image}" \ - "${tap_merged_detailed}" + if [ ${skip_copy_to_bincache} -eq 0 ] + # publish kola output, TAP files to build cache + copy_to_buildcache "testing/${vernum}/${arch}/${image}" \ + "${tests_dir}/_kola_temp" + copy_to_buildcache "testing/${vernum}/${arch}/${image}" \ + "${tests_dir}/"*.tap + copy_to_buildcache "testing/${vernum}/${arch}/${image}" \ + "${tap_merged_summary}" + copy_to_buildcache "testing/${vernum}/${arch}/${image}" \ + "${tap_merged_detailed}" + fi + if ! $success; then + return 1 + fi } # -- diff --git a/ci-automation/vendor-testing/qemu.sh b/ci-automation/vendor-testing/qemu.sh index 8977f254eb..c739fb8bc3 100755 --- a/ci-automation/vendor-testing/qemu.sh +++ b/ci-automation/vendor-testing/qemu.sh @@ -22,7 +22,7 @@ fi # Fetch image and BIOS if not present if [ -f "${QEMU_IMAGE_NAME}" ] ; then - echo "++++ ${CIA_TESTSCRIPT}: Using existing ./${QEMU_IMAGE_NAME} for testing ${CIA_VERNUM} (${CIA_ARCH}) ++++" + echo "++++ ${CIA_TESTSCRIPT}: Using existing ${QEMU_IMAGE_NAME} for testing ${CIA_VERNUM} (${CIA_ARCH}) ++++" else echo "++++ ${CIA_TESTSCRIPT}: downloading ${QEMU_IMAGE_NAME} for ${CIA_VERNUM} (${CIA_ARCH}) ++++" rm -f "${QEMU_IMAGE_NAME}.bz2"