Harden CI
Merged
VI
2mo ago+479+479+012345678901234567890123456789-117-117-012345678901234567890123456789
- Do not restore the Rust and npm caches in
build-js-binariesandbuild-wasmon tag and release runs, as these jobs build the native binaries and wasm published to npm. - Install
cargo-fuzzwith a pinned version and--locked, so that its dependencies are the ones from its published lockfile. - Install
twinefromuv.lock(newbuilddependency group) instead ofuvx, and check wheels integrity withunzip -tininspect-python-assets. - Verify the uv installer provenance with
gh attestation verifyon the host before running it in the manylinux container of the PGO runtime wheel build, instead of pipingcurltosh. - Remove the unused
contents: writepermission from the npm release job. - Scope the
id-token: writepermission to the CodSpeed job instead of the whole workflow. - Disable the uv cache in the PyPI release job.
- Update all GitHub Actions to the commit of their latest release, with matching version comments (except
dtolnay/rust-toolchain, which has no release versioning). This includes major bumps ofactions/checkout,actions/setup-node,actions/setup-python,astral-sh/setup-uv,CodSpeedHQ/action,codecov/codecov-actionandj178/prek-action.
Summary by cubic
Hardens the CI pipeline against supply chain attacks: release jobs no longer trust cached or unpinned tooling, the uv installer is provenance-checked, and workflow permissions are narrowed.
Supply chain hardening
- Skip Rust and npm cache restores in
build-js-binariesandbuild-wasmon tag and release runs, since these jobs publish the native binaries and wasm. - Pin
cargo-fuzzto 0.13.2 and install with--locked, so its dependencies come from its published lockfile. - Install
twinefrom the newbuilddependency group inuv.lockinstead ofuvx, and check every wheel's zip integrity withunzip -tbefore release. - Verify the uv installer with
gh attestation verifyon the host before running it in the manylinux container of the PGO runtime wheel build. - Remove the unused
contents: writepermission from the npm release job, scopeid-token: writeto the CodSpeed job only, and disable the uv cache in the PyPI release andinspect-python-assetsjobs.
Dependencies
- Update all GitHub Actions to their latest release commits, including major bumps of
actions/checkout,actions/setup-node,actions/setup-python,astral-sh/setup-uv,CodSpeedHQ/action,codecov/codecov-action, andj178/prek-action. - Add Dependabot for GitHub Actions with a monthly schedule.