From ce24e983584b32f32b61313c327255ef5cca8b5a Mon Sep 17 00:00:00 2001 From: stevenhorsman Date: Thu, 16 May 2024 17:16:21 +0100 Subject: [PATCH] ci: cache: Add tag character filtering - Container image tags can only contain alphanumeric, period, hyphen and underscore characters, so convert characters outside of these to be underscores, to avoid having invalid tag failures Signed-off-by: stevenhorsman --- tools/packaging/kata-deploy/local-build/kata-deploy-binaries.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/packaging/kata-deploy/local-build/kata-deploy-binaries.sh b/tools/packaging/kata-deploy/local-build/kata-deploy-binaries.sh index 77f7a32e7f..1c0f0646d5 100755 --- a/tools/packaging/kata-deploy/local-build/kata-deploy-binaries.sh +++ b/tools/packaging/kata-deploy/local-build/kata-deploy-binaries.sh @@ -1148,6 +1148,8 @@ handle_build() { echo "Pushing ${build_target} with tags: ${tags[*]}" for tag in "${tags[@]}"; do + # tags can only contain lowercase and uppercase letters, digits, underscores, periods, and hyphens + tag=("$(echo ${tag} | tr -c '[a-zA-Z0-9\_\.\-]' _)") case ${build_target} in kernel-nvidia-gpu) sudo oras push \