From 3667eea89307169f2bba02d230c5ca157cd58518 Mon Sep 17 00:00:00 2001 From: Chris Date: Sun, 27 Sep 2026 14:22:49 +0800 Subject: [PATCH] fix(ci): validate health binary without file utility (#8157) --- .github/workflows/connect-health-service-acceptance.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/connect-health-service-acceptance.yml b/.github/workflows/connect-health-service-acceptance.yml index 01afb2a16..45426c8a2 100644 --- a/.github/workflows/connect-health-service-acceptance.yml +++ b/.github/workflows/connect-health-service-acceptance.yml @@ -177,11 +177,13 @@ jobs: assert inner.testzip() is None pathlib.Path('binary').mkdir() with inner.open('rustfs') as source, open('binary/rustfs', 'xb') as destination: + header = source.read(20) + assert header[:7] == b'\x7fELF\x02\x01\x01' and header[18:20] == b'\x3e\x00', 'Expected a little-endian ELF64 x86-64 binary' + destination.write(header) shutil.copyfileobj(source, destination) PY chmod 0755 binary/rustfs printf '%s binary/rustfs\n' "$BINARY_SHA256" | sha256sum --check --strict - file binary/rustfs | grep -Eq 'ELF 64-bit LSB.*x86-64' - name: Run the real health service job shell: bash