From 82cef2b488381ef8871c48aa42c7ae2dccd22786 Mon Sep 17 00:00:00 2001 From: shiva kumar Date: Fri, 22 Nov 2024 21:57:11 +0530 Subject: [PATCH] ubuntu24.04 ci pipeline fix Signed-off-by: shiva kumar --- tests/scripts/findkernelversion.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/tests/scripts/findkernelversion.sh b/tests/scripts/findkernelversion.sh index 75277bf2..e64ab41a 100755 --- a/tests/scripts/findkernelversion.sh +++ b/tests/scripts/findkernelversion.sh @@ -17,11 +17,11 @@ chmod a+x bin/regctl export PATH=$(pwd)/bin:${PATH} # calculate kernel version of latest image -echo -e "SHIVA1 ${BASE_TARGET}-${KERNEL_FLAVOR}-${DRIVER_BRANCH} " +# echo -e "SHIVA1 ${BASE_TARGET}-${KERNEL_FLAVOR}-${DRIVER_BRANCH} " regctl image get-file ghcr.io/nvidia/driver:base-${BASE_TARGET}-${KERNEL_FLAVOR}-${DRIVER_BRANCH} /var/kernel_version.txt ./kernel_version.txt 2>/dev/null || true if [[ -f ./kernel_version.txt && -s ./kernel_version.txt ]]; then # File exists and is not empty - echo -e "SHIVA2 " + # echo -e "SHIVA2 " export $(grep -oP 'KERNEL_VERSION=[^ ]+' ./kernel_version.txt) rm -f kernel_version.txt else @@ -29,13 +29,13 @@ else prefix="kernel-version-${DRIVER_BRANCH}-${LTS_KERNEL}" suffix="${kernel_flavor}-${DIST}" artifacts=$(gh api -X GET /repos/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}/artifacts --jq '.artifacts[].name') - echo -e "SHIVA2 $artifacts" + # echo -e "SHIVA2 $artifacts" # Use a loop or a pattern to find the matching artifact dynamically for artifact in $artifacts; do - echo -e "SHIVA2 $artifact" + # echo -e "SHIVA2 $artifact" if [[ $artifact == $prefix*-$suffix ]]; then gh run download --name "$artifact" --dir ./ - tar -xvf $artifact.tar + tar -xf $artifact.tar rm -f $artifact.tar cat ./kernel_version.txt export $(grep -oP 'KERNEL_VERSION=[^ ]+' ./kernel_version.txt) @@ -71,9 +71,9 @@ fi # calculate driver tag status=0 -echo -e "SHIVA4" +# echo -e "SHIVA4" regctl tag ls nvcr.io/nvidia/driver | grep "^${DRIVER_BRANCH}-${KERNEL_VERSION}-${DIST}$" || status=$? -echo -e "SHIVA5" +# echo -e "SHIVA5" if [[ $status -eq 0 ]]; then export should_continue=false else