diff --git a/ct.sh b/ct.sh index 151baa3..b76da48 100755 --- a/ct.sh +++ b/ct.sh @@ -80,7 +80,11 @@ install_chart_testing() { fi local arch - arch=$(uname -m) + if [[ $(uname -m) == "aarch64" ]]; then + arch=arm64 + else + arch=amd64 + fi local cache_dir="$RUNNER_TOOL_CACHE/ct/$version/$arch" local venv_dir="$cache_dir/venv" @@ -88,10 +92,10 @@ install_chart_testing() { mkdir -p "$cache_dir" echo "Installing chart-testing ${version}..." - CT_CERT=https://github.com/helm/chart-testing/releases/download/$version/chart-testing_${version#v}_linux_amd64.tar.gz.pem - CT_SIG=https://github.com/helm/chart-testing/releases/download/$version/chart-testing_${version#v}_linux_amd64.tar.gz.sig + CT_CERT=https://github.com/helm/chart-testing/releases/download/$version/chart-testing_${version#v}_linux_$arch.tar.gz.pem + CT_SIG=https://github.com/helm/chart-testing/releases/download/$version/chart-testing_${version#v}_linux_$arch.tar.gz.sig - curl --retry 5 --retry-delay 1 -sSLo ct.tar.gz "https://github.com/helm/chart-testing/releases/download/$version/chart-testing_${version#v}_linux_amd64.tar.gz" + curl --retry 5 --retry-delay 1 -sSLo ct.tar.gz "https://github.com/helm/chart-testing/releases/download/$version/chart-testing_${version#v}_linux_$arch.tar.gz" cosign verify-blob --certificate $CT_CERT --signature $CT_SIG \ --certificate-identity "https://github.com/helm/chart-testing/.github/workflows/release.yaml@refs/heads/main" \ --certificate-oidc-issuer "https://token.actions.githubusercontent.com" ct.tar.gz