Add new verify and fix targets for GH actions#639
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Pull request overview
Introduces pinact into the makefile-modules toolchain and adds Make targets to verify/fix pinned GitHub Actions digests while ensuring version comments match, improving workflow readability and pinning hygiene.
Changes:
- Add
pinactas a managed tool (version + Go install source). - Add
verify-pinact/fix-pinacttargets under a newgh-actionsmodule. - Include the new module from the repository Makefile so targets participate in
make verify.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| modules/tools/00_mod.mk | Adds pinact to the managed tool/version list and Go dependency install list. |
| modules/gh-actions/01_mod.mk | Introduces verify-pinact and fix-pinact Make targets using pinact. |
| Makefile | Includes the new modules/gh-actions/01_mod.mk module. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Signed-off-by: Erik Godding Boye <egboye@gmail.com>
|
/cc @inteon |
Today I found https://github.com/suzuki-shunsuke/pinact, which seems like a useful tool to ensure pinned actions correspond with version comments. This is something I have been trying to manually fix in a lot of our repos, but I still think there are leftovers. Having a check that an action digest corresponds to the release in the comment behind the action declaration will also improve security, but the biggest benefit IMO is to make things more human-readable and avoid PRs from Renovate just bumping a digest for an action. These PRs always make me suspicious.
I am proposing a new module for this, which could also be used as a new home for generic reusable GH workflows. I am planning to change #651 after this is merged to source the OSSF Scorecard workflow from this new module. Also planning to source https://github.com/cert-manager/makefile-modules/blob/main/.github/workflows/validate-renovate-config.yaml from the module