From c24353af93b1b18d75868f7c57a570e2364a3f7e Mon Sep 17 00:00:00 2001 From: Chisanan232 Date: Mon, 1 Jun 2026 21:20:46 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20(ci):=20Add=20apt-get=20fallback?= =?UTF-8?q?=20to=20before-script-linux=20for=20Debian-based=20cross=20cont?= =?UTF-8?q?ainer?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Follow-up to AAASM-2189. That fix's before-script-linux only handles yum + dnf, assuming all manylinux containers are RHEL-family. The aarch64 cross-compile container ghcr.io/rust-cross/manylinux2014-cross:aarch64 is actually Debian-based (Ubuntu jammy) and has neither yum nor dnf. v0.0.1-alpha.3 dry-run, Build manylinux_aarch64 wheel job: /home/runner/.../run-maturin-action.sh: line 24: yum: command not found /home/runner/.../run-maturin-action.sh: line 24: dnf: command not found Error: The process '/usr/bin/docker' failed with exit code 127 The x86_64 manylinux2014 image (CentOS 7-based) still uses yum. The aarch64 cross image uses apt-get. Extend the fallback chain to try all three: (command -v unzip >/dev/null) || ( yum install -y unzip 2>/dev/null || dnf install -y unzip 2>/dev/null || (apt-get update && apt-get install -y unzip) ) Verified locally inside ghcr.io/rust-cross/manylinux2014-cross:aarch64: * Container confirmed Debian-based (Ubuntu jammy), no yum/dnf * apt-get install -y unzip succeeds * protoc 32.1 downloads + SHA-256 verifies + extracts * libprotoc 32.1 confirmed working My reviewer-miss documented: I shipped AAASM-2189 with only x86_64 local verification. Should have tested both targets locally before pushing. Pattern to remember: matrix entries with different base images need each base image verified, not just one. Tracked: AAASM-2327 --- .github/workflows/release-python.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release-python.yml b/.github/workflows/release-python.yml index 402f51c..52ff3f6 100644 --- a/.github/workflows/release-python.yml +++ b/.github/workflows/release-python.yml @@ -92,7 +92,7 @@ jobs: # be installing an arbitrary binary as root with no integrity gate. before-script-linux: | set -euo pipefail - (command -v unzip >/dev/null) || (yum install -y unzip || dnf install -y unzip) + (command -v unzip >/dev/null) || (yum install -y unzip 2>/dev/null || dnf install -y unzip 2>/dev/null || (apt-get update && apt-get install -y unzip)) ARCH=$(uname -m) case "$ARCH" in x86_64) PROTOC_ARCH="x86_64"; EXPECTED_SHA="${{ env.PROTOC_SHA256_X86_64 }}" ;; @@ -144,7 +144,7 @@ jobs: # SHA-verified protoc binary download. before-script-linux: | set -euo pipefail - (command -v unzip >/dev/null) || (yum install -y unzip || dnf install -y unzip) + (command -v unzip >/dev/null) || (yum install -y unzip 2>/dev/null || dnf install -y unzip 2>/dev/null || (apt-get update && apt-get install -y unzip)) ARCH=$(uname -m) case "$ARCH" in x86_64) PROTOC_ARCH="x86_64"; EXPECTED_SHA="${{ env.PROTOC_SHA256_X86_64 }}" ;;