Pin actions/cache to a commit SHA - #68
Open
nohwnd wants to merge 1 commit into
Open
Conversation
Same version, v5.0.5, just referenced by SHA so the action works in repositories that require SHA pinning. 🤖
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 freeto 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.
GitHub's "Require actions to be pinned to a full-length commit SHA" policy (Settings > Actions > General) applies to actions referenced inside a composite action, not only to the ones in the consumer's own workflow. So a repository that turns the policy on and uses psmodulecache fails at Set up job, before anything runs:
We ran into this in pester/Pester. We have pinned every action in our own workflows, so this nested reference is the one thing left that keeps us from turning the policy on. There is no way to fix it from the consumer side, which is why I am sending it here.
Same version, no behaviour change:
27d5ce7f107fe9357f9df03efb73ab90386fccaeis the commitv5.0.5points at. Dependabot updates the SHA and the trailing version comment together, so it does not become manual work.Happy to do the same for the workflows under
.github/if you want. I kept this toaction.ymlsince that is the part consumers execute.🤖