Skip to content

Commit

Permalink
[#70544] use the same version of renode as the dashboards
Browse files Browse the repository at this point in the history
  • Loading branch information
laudominik committed Jan 14, 2025
1 parent 1ba810d commit 6f9d4d5
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 16 deletions.
6 changes: 3 additions & 3 deletions .ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ Test Static release:
stage: Test
image: debian:bullseye
variables:
RENODE_VERSION: "latest"
DEBIAN_FRONTEND: "noninteractive"
GET_CUSTOM_RENODE_REVISION: ""
RENODE_VERSION: "" # defaults to the one used on appropriate dashboard
artifacts:
paths:
- ci-output/repls
Expand All @@ -69,15 +69,15 @@ Test Static release:
Compare repls uboot:
<<: *compare_repls
variables:
RENODE_VERSION: "latest"
DEBIAN_FRONTEND: "noninteractive"
GET_CUSTOM_RENODE_REVISION: ""
RENODE_VERSION: "" # defaults to renode used on uboot-dashboard
DASHBOARD_VARIANT: "uboot"

Compare repls zephyr:
<<: *compare_repls
variables:
RENODE_VERSION: "latest"
DEBIAN_FRONTEND: "noninteractive"
GET_CUSTOM_RENODE_REVISION: ""
RENODE_VERSION: "" # defaults to renode used on zephyr-dashboard
DASHBOARD_VARIANT: "zephyr"
14 changes: 1 addition & 13 deletions ci/get_dashboard_replkit.sh
Original file line number Diff line number Diff line change
@@ -1,19 +1,7 @@
#!/bin/bash
set -euo pipefail

if [[ "$DASHBOARD_VARIANT" == "zephyr" ]]; then
GCP_SIM_BASE="https://zephyr-dashboard.renode.io/zephyr_sim"
export DEMO_NAME=hello_world
elif [[ "$DASHBOARD_VARIANT" == "uboot" ]]; then
GCP_SIM_BASE="https://u-boot-dashboard.renode.io/uboot_sim"
export DEMO_NAME=uboot
else
exit 1
fi

LATEST_SIM=$(curl --fail -sS -G "$GCP_SIM_BASE"/latest)
LATEST_RENODE=$(curl --fail -sS -G "$GCP_SIM_BASE"/"$LATEST_SIM"/latest)
wget "$GCP_SIM_BASE"/"$LATEST_SIM"/"$LATEST_RENODE"/replkit.tar.xz
wget "$GCP_SIM_BASE"/"$LATEST_SIM"/"$LATEST_SIM_RENODE"/replkit.tar.xz

mkdir replkit
tar xf replkit.tar.xz -C replkit >/dev/null
Expand Down
18 changes: 18 additions & 0 deletions ci/get_versions_from_dashboard.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/bash

if [[ "$DASHBOARD_VARIANT" == "zephyr" ]]; then
export GCP_SIM_BASE="https://zephyr-dashboard.renode.io/zephyr_sim"
export DEMO_NAME=hello_world
elif [[ "$DASHBOARD_VARIANT" == "uboot" ]]; then
export GCP_SIM_BASE="https://u-boot-dashboard.renode.io/uboot_sim"
export DEMO_NAME=uboot
else
exit 1
fi

export LATEST_SIM=$(curl --fail -sS -G "$GCP_SIM_BASE"/latest)
export LATEST_SIM_RENODE=$(curl --fail -sS -G "$GCP_SIM_BASE"/"$LATEST_SIM"/latest)

if [ -z "$RENODE_VERSION" ]; then
export RENODE_VERSION="$LATEST_SIM_RENODE"
fi
3 changes: 3 additions & 0 deletions ci/prepare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ echo -e "=================================================\n"
# install dts2repl as module
pip3 install .

# get renode & latest simulation version to be used by the CI
. ./ci/get_versions_from_dashboard.sh

# download replkit and prepare dts/repl directory structure
mkdir -p ci-output/{repls/{dashboard,generated,diffs},dts}
(cd ci-output && ../ci/get_dashboard_replkit.sh)
Expand Down

0 comments on commit 6f9d4d5

Please sign in to comment.