Pin write-token GitHub Actions refs - #1782
Open
alvarosanchez wants to merge 2 commits into
Open
alvarosanchez wants to merge 2 commits into
alvarosanchez wants to merge 2 commits into
Conversation
alvarosanchez
force-pushed
the
DEV-508-pin-write-token-actions
branch
from
May 25, 2026 16:54
ea23c4d to
96591b1
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
This PR hardens the repository’s GitHub Actions workflows by replacing mutable action refs (e.g., @v4, @master) with pinned commit SHAs, and by adding top-level least-privilege permissions blocks to the modified workflows.
Changes:
- Pin
actions/checkout,actions/setup-java,actions/cache, andmicronaut-projects/github-pages-deploy-actionto specific commit SHAs. - Add top-level
permissions: contents: readto affected workflows.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| .github/workflows/snapshot.yml | Pins action refs to SHAs and adds least-privilege top-level permissions for the snapshot test workflow. |
| .github/workflows/publish.yml | Pins action refs to SHAs and adds top-level permissions for the publish workflow (but currently contains a misconfigured cache step). |
| .github/workflows/gradle.yml | Pins action refs to SHAs and adds least-privilege top-level permissions for the main test workflow. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pins the GitHub Actions refs in the guides workflows to commit SHAs (version in a comment), and adds top-level
permissions: contents: readto thegradle,manual,publishandsnapshotworkflows.Checked that the changed workflows parse as YAML and that no action ref is still mutable.
✨ This message was AI-generated using gpt-5.5