mirror of
https://github.com/flatcar/scripts.git
synced 2025-09-22 14:11:07 +02:00
ci-automation: Drop boilerplate code from digital ocean test
This commit is contained in:
parent
2fe896b558
commit
cd2f3f0d6c
@ -8,38 +8,22 @@ set -euo pipefail
|
|||||||
# Test execution script for the Digital Ocean vendor image.
|
# Test execution script for the Digital Ocean vendor image.
|
||||||
# This script is supposed to run in the mantle container.
|
# This script is supposed to run in the mantle container.
|
||||||
|
|
||||||
work_dir="$1"; shift
|
source ci-automation/vendor_test.sh
|
||||||
arch="$1"; shift
|
|
||||||
vernum="$1"; shift
|
|
||||||
tapfile="$1"; shift
|
|
||||||
|
|
||||||
# $@ now contains tests / test patterns to run
|
|
||||||
|
|
||||||
source ci-automation/ci_automation_common.sh
|
|
||||||
source sdk_lib/sdk_container_common.sh
|
|
||||||
|
|
||||||
mkdir -p "${work_dir}"
|
|
||||||
cd "${work_dir}"
|
|
||||||
|
|
||||||
# We never ran Digital Ocean on arm64, so for now fail it as an
|
# We never ran Digital Ocean on arm64, so for now fail it as an
|
||||||
# unsupported option.
|
# unsupported option.
|
||||||
if [[ "${arch}" == "arm64" ]]; then
|
if [[ "${CIA_ARCH}" == "arm64" ]]; then
|
||||||
echo "1..1" > "${tapfile}"
|
echo "1..1" > "${CIA_TAPFILE}"
|
||||||
echo "not ok - all digital ocean tests" >> "${tapfile}"
|
echo "not ok - all Digital Ocean tests" >> "${CIA_TAPFILE}"
|
||||||
echo " ---" >> "${tapfile}"
|
echo " ---" >> "${CIA_TAPFILE}"
|
||||||
echo " ERROR: ARM64 tests not supported on Digital Ocean." | tee -a "${tapfile}"
|
echo " ERROR: ARM64 tests not supported on Digital Ocean." | tee -a "${CIA_TAPFILE}"
|
||||||
echo " ..." >> "${tapfile}"
|
echo " ..." >> "${CIA_TAPFILE}"
|
||||||
break_retest_cycle
|
break_retest_cycle
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
channel="$(get_git_channel)"
|
image_name="ci-${CIA_VERNUM//+/-}"
|
||||||
if [[ "${channel}" = 'developer' ]]; then
|
image_url="$(url_from_template "${DO_IMAGE_URL}" "${CIA_ARCH}" "${CIA_CHANNEL}" 'https' "${CIA_VERNUM}")"
|
||||||
channel='alpha'
|
|
||||||
fi
|
|
||||||
image_name="ci-${vernum//+/-}"
|
|
||||||
testscript="$(basename "$0")"
|
|
||||||
image_url="$(url_from_template "${DO_IMAGE_URL}" "${arch}" "${channel}" 'https' "${vernum}")"
|
|
||||||
|
|
||||||
ore do create-image \
|
ore do create-image \
|
||||||
--config-file="${DO_CONFIG_FILE}" \
|
--config-file="${DO_CONFIG_FILE}" \
|
||||||
@ -62,9 +46,9 @@ timeout --signal=SIGQUIT 4h\
|
|||||||
--do-image="${image_name}" \
|
--do-image="${image_name}" \
|
||||||
--parallel="${DO_PARALLEL}" \
|
--parallel="${DO_PARALLEL}" \
|
||||||
--platform=do \
|
--platform=do \
|
||||||
--channel="${channel}" \
|
--channel="${CIA_CHANNEL}" \
|
||||||
--tapfile="${tapfile}" \
|
--tapfile="${CIA_TAPFILE}" \
|
||||||
--torcx-manifest='../torcx_manifest.json' \
|
--torcx-manifest="${CIA_TORCX_MANIFEST}" \
|
||||||
"${@}"
|
"${@}"
|
||||||
|
|
||||||
set +x
|
set +x
|
||||||
|
Loading…
x
Reference in New Issue
Block a user