From 15949180c94d7288ae0370f6625409b0a1412b8d Mon Sep 17 00:00:00 2001 From: hector <42570491+majinghe@users.noreply.github.com> Date: Wed, 9 Sep 2026 18:33:16 +0800 Subject: [PATCH] =?UTF-8?q?fix(nightly):=20push=20assets=20with=20plain=20?= =?UTF-8?q?git=20on=20release=20=E2=80=94=20the=20build=20fleet=20has=20no?= =?UTF-8?q?=20gh=20CLI=20(#7586)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fix(nightly): push assets with plain git — the build fleet has no gh CLI The sm-standard-4 runners used by the nightly build have no gh binary (functional-chain workflows run elsewhere, on the jumpbox). The assets publish step died on 'gh: command not found' at the credential-helper setup, and the preceding clone failure had been masked by 2>/dev/null, misleading the step into the orphan path. Swap clone and remote setup to plain git with the token embedded in the URL; push semantics are unchanged. --- .github/workflows/nightly-gnu.yml | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/.github/workflows/nightly-gnu.yml b/.github/workflows/nightly-gnu.yml index 6d7920f5e..8f1480084 100644 --- a/.github/workflows/nightly-gnu.yml +++ b/.github/workflows/nightly-gnu.yml @@ -372,15 +372,18 @@ jobs: [ -f "$f" ] || { echo "missing package: $f"; exit 1; } done + # Plain git + token URL: the build fleet has no gh CLI. + ASSETS_URL="https://x-access-token:${ASSETS_TOKEN}@github.com/rustfs/auto-testing.git" rm -rf assets-work && mkdir assets-work - if ! gh repo clone rustfs/auto-testing assets-work -- --depth 1 --branch assets --quiet 2>/dev/null; then + if git clone -q --depth 1 --branch assets "${ASSETS_URL}" assets-work 2>/dev/null; then + echo "assets branch cloned" + else echo "assets branch does not exist yet; creating an orphan" - ( cd assets-work && git init -q -b assets ) + git -C assets-work init -q -b assets fi cd assets-work - git remote add origin "https://github.com/rustfs/auto-testing.git" 2>/dev/null || \ - git remote set-url origin "https://github.com/rustfs/auto-testing.git" - gh auth setup-git >/dev/null + git remote add origin "${ASSETS_URL}" 2>/dev/null || \ + git remote set-url origin "${ASSETS_URL}" mkdir -p nightly cp "../${DEB_FILE}" "nightly/${DEB_FILE}"