Merge pull request #1031 from warmbly/feat/ci-pinned-protoc

Install a pinned, digest-verified protoc in Go CI
This commit is contained in:
Matthew Meszaros
2026-10-22 16:22:19 +00:00
committed by GitHub
+13 -4
View File
@@ -181,11 +181,20 @@ jobs:
go-version-file: go.mod
cache: true
# A pinned release verified by digest; resolving "latest" lists every protobuf release and fails when that listing is cut short.
- name: Set up protoc
uses: arduino/setup-protoc@v3
with:
version: "33.x"
repo-token: ${{ github.token }}
env:
PROTOC_VERSION: "33.6"
PROTOC_SHA256: 9c49962391ff8b5754342509efc3885db91dfe11a358e1e98c9a71518f0ad199
run: |
set -eu
archive="$RUNNER_TEMP/protoc.zip"
curl -fsSL --retry 5 --retry-all-errors -o "$archive" \
"https://github.com/protocolbuffers/protobuf/releases/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-x86_64.zip"
echo "${PROTOC_SHA256} ${archive}" | sha256sum -c -
unzip -q -o "$archive" -d "$RUNNER_TEMP/protoc"
echo "$RUNNER_TEMP/protoc/bin" >> "$GITHUB_PATH"
"$RUNNER_TEMP/protoc/bin/protoc" --version
- name: Install required Go tools
run: make setup-tools