From 3536490d19e4acfd792995c5983dc6bf554f9d84 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=9B=B7=E7=94=B5=E8=8A=BD=E8=A1=A3?= Date: Wed, 12 Aug 2026 23:30:16 -0400 Subject: [PATCH] CI: add runner smoke-test workflow to probe Gitea runners Co-Authored-By: Claude Fable 5 --- .gitea/workflows/runner-smoke.yml | 117 ++++++++++++++++++++++++++++++ 1 file changed, 117 insertions(+) create mode 100644 .gitea/workflows/runner-smoke.yml diff --git a/.gitea/workflows/runner-smoke.yml b/.gitea/workflows/runner-smoke.yml new file mode 100644 index 00000000..81cb7c91 --- /dev/null +++ b/.gitea/workflows/runner-smoke.yml @@ -0,0 +1,117 @@ +name: Runner Smoke Test +on: + workflow_dispatch: + +jobs: + windows-probe: + runs-on: windows-latest + steps: + - name: Basic info (cmd) + shell: cmd + run: | + echo == hostname == & hostname + echo == user == & echo %USERNAME% + ver + echo == node == & node -v 2>NUL || echo node NOT FOUND + echo == npm == & call npm -v 2>NUL || echo npm NOT FOUND + echo == pnpm == & call pnpm -v 2>NUL || echo pnpm NOT FOUND + echo == corepack == & call corepack --version 2>NUL || echo corepack NOT FOUND + echo == git == & git --version 2>NUL || echo git NOT FOUND + echo == where node == & where node 2>NUL || echo - + echo == where pnpm == & where pnpm 2>NUL || echo - + echo == where curl == & where curl 2>NUL || echo - + echo == where pwsh == & where pwsh 2>NUL || echo - + echo == where bash == & where bash 2>NUL || echo - + echo == free disk == & wmic logicaldisk where "DeviceID='C:'" get FreeSpace 2>NUL || echo - + exit /b 0 + - name: PowerShell 5 probe + continue-on-error: true + shell: powershell + run: | + Write-Output "powershell OK: $($PSVersionTable.PSVersion)" + - name: pwsh probe + continue-on-error: true + shell: pwsh + run: | + Write-Output "pwsh OK: $($PSVersionTable.PSVersion)" + - name: bash probe + continue-on-error: true + shell: bash + run: | + echo "bash OK: $BASH_VERSION" + - name: default shell probe + continue-on-error: true + run: | + echo "default shell step OK" + - name: checkout probe + id: checkout + continue-on-error: true + uses: actions/checkout@v4 + - name: post-checkout listing + continue-on-error: true + shell: cmd + run: | + echo checkout outcome was: ${{ steps.checkout.outcome }} + dir /b + exit /b 0 + - name: token API probe + continue-on-error: true + shell: cmd + env: + API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + curl.exe -s -o NUL -w "repo GET status: %%{http_code}" -H "Authorization: token %API_TOKEN%" "%GITHUB_SERVER_URL%/api/v1/repos/%GITHUB_REPOSITORY%" + + macos-probe: + runs-on: macos-latest + steps: + - name: Basic info + run: | + echo "== uname =="; uname -a + echo "== sw_vers =="; sw_vers || true + echo "== whoami =="; whoami + echo "== HOME =="; echo "$HOME" + echo "== shell =="; echo "$SHELL" + echo "== node =="; command -v node && node -v || echo "node NOT FOUND" + echo "== npm =="; command -v npm && npm -v || echo "npm NOT FOUND" + echo "== pnpm =="; command -v pnpm && pnpm -v || echo "pnpm NOT FOUND" + echo "== corepack =="; command -v corepack && corepack --version || echo "corepack NOT FOUND" + echo "== git =="; git --version || echo "git NOT FOUND" + echo "== python3 =="; command -v python3 || echo "-" + echo "== free disk =="; df -h / | tail -1 + - name: Xcode / notarytool + continue-on-error: true + run: | + echo "== xcode-select =="; xcode-select -p || true + echo "== xcodebuild =="; xcodebuild -version || true + echo "== notarytool =="; xcrun notarytool --version || true + echo "== stapler =="; xcrun stapler version || true + - name: Code signing identities + continue-on-error: true + run: | + echo "== default keychain =="; security default-keychain || true + echo "== keychains =="; security list-keychains || true + echo "== codesigning identities =="; security find-identity -v -p codesigning || true + - name: Apple/CSC env var names (values hidden) + continue-on-error: true + run: | + echo "== APPLE_* env names ==" + env | cut -d= -f1 | grep -i '^APPLE' || echo "(none)" + echo "== CSC/notarize-related env names ==" + env | cut -d= -f1 | grep -iE 'CSC|NOTAR|^AC_' || echo "(none)" + - name: checkout probe + id: checkout + continue-on-error: true + uses: actions/checkout@v4 + - name: post-checkout listing + continue-on-error: true + run: | + echo "checkout outcome was: ${{ steps.checkout.outcome }}" + ls -1 | head -30 + - name: token API probe + continue-on-error: true + env: + API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + code=$(curl -s -o /dev/null -w "%{http_code}" -H "Authorization: token $API_TOKEN" "$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY") + echo "repo GET status: $code"