Skip to content

Commit 2fad4cf

Browse files
Merge pull request #81 from grafana/fix/update-runner-to-x64-large
Fix architecture detection for cross-platform TruffleHog support
2 parents 1740852 + 1624045 commit 2fad4cf

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

.github/workflows/org-required-trufflehog.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@ jobs:
2424
fail-on-verified: "false" # Don't block on verified secrets (monitoring only)
2525
fail-on-unverified: "false" # Don't block on unverified secrets
2626
runs-on: ${{ !github.event.repository.private && 'ubuntu-latest' || 'ubuntu-arm64-small' }} # Use same runner pattern as zizmor
27-
secrets: inherit
27+
secrets: inherit

.github/workflows/reusable-trufflehog.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,12 @@ jobs:
4242
run: |
4343
# Download binary directly from GitHub releases for supply chain security
4444
VERSION="v${{ env.TRUFFLEHOG_VERSION }}"
45-
ARCH="linux_amd64"
45+
# Auto-detect architecture for cross-platform support
46+
if [[ "$(uname -m)" == "aarch64" ]]; then
47+
ARCH="linux_arm64"
48+
else
49+
ARCH="linux_amd64"
50+
fi
4651
BINARY_URL="https://github.com/trufflesecurity/trufflehog/releases/download/${VERSION}/trufflehog_${VERSION#v}_${ARCH}.tar.gz"
4752
4853
curl -sSfL "${BINARY_URL}" | tar -xz -C /tmp

0 commit comments

Comments
 (0)