Skip to content

Commit ac26bbb

Browse files
authored
Merge pull request #2873 from flatcar/tormath1/akamai
ci-automation: add akamai testing
2 parents 8f9aa21 + c193d08 commit ac26bbb

File tree

4 files changed

+51
-0
lines changed

4 files changed

+51
-0
lines changed

ci-automation/ci-config.env

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,3 +173,9 @@ BRIGHTBOX_PARALLEL="${PARALLEL_TESTS:-1}"
173173
: ${HETZNER_arm64_LOCATION:="fsn1"}
174174
: ${HETZNER_amd64_LOCATION:="hel1"}
175175
HETZNER_PARALLEL="${PARALLEL_TESTS:-1}"
176+
177+
# -- Akamai --
178+
: ${AKAMAI_IMAGE_NAME:='flatcar_production_akamai_image.bin.gz'}
179+
AKAMAI_PARALLEL="${PARALLEL_TESTS:-1}"
180+
AKAMAI_REGION="us-ord"
181+
AKAMAI_INSTANCE_TYPE="g6-standard-2"

ci-automation/garbage_collect.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,7 @@ function _garbage_collect_impl() {
263263
--env VMWARE_ESX_CREDS \
264264
--env OPENSTACK_CREDS \
265265
--env BRIGHTBOX_CLIENT_ID --env BRIGHTBOX_CLIENT_SECRET \
266+
--env AKAMAI_TOKEN \
266267
-w /work -v "$PWD":/work "${mantle_ref}" /work/ci-automation/garbage_collect_cloud.sh
267268

268269
echo

ci-automation/garbage_collect_cloud.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ timeout --signal=SIGQUIT 60m ore openstack gc --duration 6h \
1111
--config-file=<(echo "${OPENSTACK_CREDS}" | base64 --decode)
1212
timeout --signal=SIGQUIT 60m ore brightbox gc --duration 6h \
1313
--brightbox-client-id="${BRIGHTBOX_CLIENT_ID}" --brightbox-client-secret="${BRIGHTBOX_CLIENT_SECRET}"
14+
timeout --signal=SIGQUIT 60m ore akamai gc --duration 6h \
15+
--akamai-token="${AKAMAI_TOKEN}"
1416
secret_to_file aws_credentials_config_file "${AWS_CREDENTIALS}"
1517
for channel in alpha beta stable lts; do
1618
for arch in amd64 arm64; do
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
#!/bin/bash
2+
# Copyright (c) 2023 The Flatcar Maintainers.
3+
# Use of this source code is governed by a BSD-style license that can be
4+
# found in the LICENSE file.
5+
6+
set -euo pipefail
7+
8+
# Test execution script for Akamai vendor.
9+
# This script is supposed to run in the mantle container.
10+
11+
source ci-automation/vendor_test.sh
12+
13+
copy_from_buildcache "images/${CIA_ARCH}/${CIA_VERNUM}/${AKAMAI_IMAGE_NAME}" .
14+
15+
kola_test_basename="ci-${CIA_VERNUM//[+.]/-}"
16+
17+
# Upload the image on Akamai.
18+
IMAGE_ID=$(ore akamai \
19+
--akamai-token="${AKAMAI_TOKEN}" \
20+
--akamai-region="${AKAMAI_REGION}" \
21+
create-image \
22+
--name "${kola_test_basename}" \
23+
--file="${AKAMAI_IMAGE_NAME}"
24+
)
25+
26+
set -x
27+
28+
timeout --signal=SIGQUIT 2h kola run \
29+
--board="${CIA_ARCH}-usr" \
30+
--parallel="${AKAMAI_PARALLEL}" \
31+
--tapfile="${CIA_TAPFILE}" \
32+
--channel="${CIA_CHANNEL}" \
33+
--basename="${kola_test_basename}" \
34+
--platform=akamai \
35+
--akamai-token="${AKAMAI_TOKEN}" \
36+
--akamai-type="${AKAMAI_INSTANCE_TYPE}" \
37+
--akamai-region="${AKAMAI_REGION}" \
38+
--akamai-image="${IMAGE_ID}" \
39+
--image-version "${CIA_VERNUM}" \
40+
"${@}"
41+
42+
set +x

0 commit comments

Comments
 (0)