fix: update action versions in workflows for consistency#77
Open
kenichiro-kimura wants to merge 5 commits into
Open
fix: update action versions in workflows for consistency#77kenichiro-kimura wants to merge 5 commits into
kenichiro-kimura wants to merge 5 commits into
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR aims to harden GitHub Actions workflows by pinning commonly used actions to specific commit SHAs for reproducible and more secure CI runs.
Changes:
- Pinned
actions/checkoutandactions/setup-nodeto commit SHAs in the lint/test workflow. - Pinned
actions/checkoutand allgithub/codeql-action/*steps to commit SHAs in the CodeQL workflow. - Pinned
actions/checkout,actions/setup-go,actions/setup-node, andsoftprops/action-gh-releaseto commit SHAs in the build/release workflow.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
.github/workflows/lint-and-test.yml |
Pins checkout and Node setup actions to SHAs. |
.github/workflows/codeql-analysis.yml |
Pins checkout and CodeQL actions to SHAs (but currently has a YAML indentation issue in steps). |
.github/workflows/build-and-release.yml |
Pins actions to SHAs (but currently removes checkout of the main repository, likely breaking the workflow). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- build-and-release.yml: Add checkout step for the main repository before checking out libsoratun, so that npm ci and other steps have access to the repo contents in the workspace root - codeql-analysis.yml: Fix mis-indented steps (align step items correctly under steps: key) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.
This pull request updates several GitHub Actions in workflow files to use specific commit SHAs instead of version tags. This change improves security and reliability by ensuring that the workflows always use the exact same version of each action, preventing unexpected changes due to upstream updates.
Workflow action pinning for improved security and reproducibility:
actions/checkoutsteps to use the specific commit SHAde0fac2e4500dabe0009e67214ff5f5447ce83ddinstead of the generic@v4tag in.github/workflows/build-and-release.yml,.github/workflows/codeql-analysis.yml, and.github/workflows/lint-and-test.yml. [1] [2] [3]actions/setup-goto use commit4a3601121dd01d1626a1e23e37211e3254c1c06cinstead of@v4in.github/workflows/build-and-release.yml.actions/setup-nodeto use commit48b55a011bda9f5d6aeb4c2d9c7362e8dae4041einstead of@v4in.github/workflows/build-and-release.ymland.github/workflows/lint-and-test.yml. [1] [2]softprops/action-gh-releaseto use commitb4309332981a82ec1c5618f44dd2e27cc8bfbfdainstead of@v2in.github/workflows/build-and-release.yml.github/codeql-actionsteps (init,autobuild,analyze) to use commit458d36d7d4f47d0dd16ca424c1d3cda0060f1360instead of@v3in.github/workflows/codeql-analysis.yml. [1] [2] [3]