Skip to content

Commit d99110f

Browse files
committed
Workaround for test-build-kontron hanging apt + renode tests moved to wolfboot-ci
1 parent 776378c commit d99110f

3 files changed

Lines changed: 67 additions & 7 deletions

File tree

.github/workflows/test-build-kontron-vx3060-s2.yml

Lines changed: 32 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,40 @@ jobs:
1212
- uses: actions/checkout@v4
1313
with:
1414
submodules: true
15+
- name: Workaround for sources.list
16+
run: |
17+
set -euxo pipefail
18+
19+
apt-cache policy
20+
grep -RInE '^(deb|Types|URIs)' /etc/apt || true
21+
22+
shopt -s nullglob
23+
24+
sudo sed -i \
25+
-e "s|https\?://azure\.archive\.ubuntu\.com/ubuntu/?|http://mirror.arizona.edu/ubuntu/|g" \
26+
/etc/apt/sources.list || true
27+
28+
for f in /etc/apt/sources.list.d/*.list; do
29+
sudo sed -i \
30+
-e "s|https\?://azure\.archive\.ubuntu\.com/ubuntu/?|http://mirror.arizona.edu/ubuntu/|g" \
31+
"$f"
32+
done
33+
34+
for f in /etc/apt/sources.list.d/*.sources; do
35+
sudo sed -i \
36+
-e "s|https\?://azure\.archive\.ubuntu\.com/ubuntu/?|http://mirror.arizona.edu/ubuntu/|g" \
37+
-e "s|https\?://azure\.archive\.ubuntu\.com|http://mirror.arizona.edu|g" \
38+
"$f"
39+
done
40+
41+
if grep -qE '^[[:space:]]*https?://azure\.archive\.ubuntu\.com/ubuntu/?' /etc/apt/apt-mirrors.txt; then
42+
sudo sed -i 's|https\?://azure\.archive\.ubuntu\.com/ubuntu/|http://mirror.arizona.edu/ubuntu/|g' /etc/apt/apt-mirrors.txt
43+
fi
1544
- name: install req
1645
run: |
17-
sudo apt-get update
18-
sudo apt-get install --no-install-recommends -y -q nasm gcc-multilib
46+
export DEBIAN_FRONTEND=noninteractive
47+
sudo apt-get update -o Acquire::Retries=3
48+
sudo apt-get install --no-install-recommends -y -q -o Acquire::Retries=3 nasm gcc-multilib
1949
- name: setup git
2050
run: |
2151
git config --global user.email "you@example.com"

.github/workflows/test-x86-fsp-qemu.yml

Lines changed: 32 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,40 @@ jobs:
1212
- uses: actions/checkout@v4
1313
with:
1414
submodules: true
15+
- name: Workaround for sources.list
16+
run: |
17+
set -euxo pipefail
18+
19+
apt-cache policy
20+
grep -RInE '^(deb|Types|URIs)' /etc/apt || true
21+
22+
shopt -s nullglob
23+
24+
sudo sed -i \
25+
-e "s|https\?://azure\.archive\.ubuntu\.com/ubuntu/?|http://mirror.arizona.edu/ubuntu/|g" \
26+
/etc/apt/sources.list || true
27+
28+
for f in /etc/apt/sources.list.d/*.list; do
29+
sudo sed -i \
30+
-e "s|https\?://azure\.archive\.ubuntu\.com/ubuntu/?|http://mirror.arizona.edu/ubuntu/|g" \
31+
"$f"
32+
done
33+
34+
for f in /etc/apt/sources.list.d/*.sources; do
35+
sudo sed -i \
36+
-e "s|https\?://azure\.archive\.ubuntu\.com/ubuntu/?|http://mirror.arizona.edu/ubuntu/|g" \
37+
-e "s|https\?://azure\.archive\.ubuntu\.com|http://mirror.arizona.edu|g" \
38+
"$f"
39+
done
40+
41+
if grep -qE '^[[:space:]]*https?://azure\.archive\.ubuntu\.com/ubuntu/?' /etc/apt/apt-mirrors.txt; then
42+
sudo sed -i 's|https\?://azure\.archive\.ubuntu\.com/ubuntu/|http://mirror.arizona.edu/ubuntu/|g' /etc/apt/apt-mirrors.txt
43+
fi
1544
- name: install req
1645
run: |
17-
sudo apt-get update
18-
sudo apt-get install --no-install-recommends -y -q nasm gcc-multilib qemu-system-x86 swtpm uuid-dev
46+
export DEBIAN_FRONTEND=noninteractive
47+
sudo apt-get update -o Acquire::Retries=3
48+
sudo apt-get install --no-install-recommends -y -q -o Acquire::Retries=3 nasm gcc-multilib qemu-system-x86 swtpm uuid-dev
1949
- name: setup git
2050
run: |
2151
git config --global user.email "you@example.com"

tools/renode/docker-test.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ declare -r HOST_TEST_RESULTS_PATH=${HOST_ROOT_DIR}/test_results
44
declare -r HOST_LOG_PATH=${HOST_TEST_RESULTS_PATH}
55
declare -r HOST_LOG_FILENAME=${HOST_LOG_PATH}/logs.txt
66

7-
declare -r DOCKER_TAG=renode_nrf52
7+
declare -r DOCKER_IMAGE="${DOCKER_IMAGE:-ghcr.io/wolfssl/wolfboot-ci-renode:latest}"
88
declare -r DOCKER_WORKSPACE=/workspace
99
declare -r DOCKER_TEST_RESULTS_PATH=/tmp/test_results
1010

1111
mkdir -p ${HOST_LOG_PATH}
1212

13-
docker build -t ${DOCKER_TAG} -f ${HOST_ROOT_DIR}/tools/renode/Dockerfile .
13+
docker pull ${DOCKER_IMAGE} >/dev/null 2>&1 || true
1414

1515
# running in `if` to avoid setting +e
1616

@@ -22,7 +22,7 @@ if ! docker run \
2222
--env SCRIPT=${DOCKER_WORKSPACE}/renode-config.resc \
2323
--env RENODE_CHECKOUT=/home/developer/renode \
2424
--workdir ${DOCKER_WORKSPACE} \
25-
${DOCKER_TAG} \
25+
${DOCKER_IMAGE} \
2626
/bin/bash -c "tools/scripts/renode-test-update.sh $@ 2>&1 > ${DOCKER_TEST_RESULTS_PATH}/logs.txt"
2727
then
2828
echo "FAILED"

0 commit comments

Comments
 (0)