Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set github actions to use commit hashes #8852

Merged
merged 2 commits into from
Mar 20, 2025
Merged

Set github actions to use commit hashes #8852

merged 2 commits into from
Mar 20, 2025

Conversation

hsubox76
Copy link
Contributor

@hsubox76 hsubox76 commented Mar 19, 2025

In light of a recent vulnerability introduced in a community Github Action (none of the ones we are using), we are switching our Github Actions to use commit hashes instead of version numbers. I am leaving the official Github Actions alone (actions/) as they are officially provided by Github and if they are compromised, Github might as well be compromised.

I left comments saying which version each corresponds to. In each case I picked a commit hash representing the same version as was previously referenced, except for hashicorp/setup-terraform which was a version behind and I thought would be safe to bump to the latest. So some may be well behind the latest version, such as google-github-actions/auth, which is 2 versions behind, as I didn't think this was the time to experiment with a version bump.

I didn't add these to renovate.json ignoreDeps because maybe we should be reminded to manually update these (after giving some time to check for vulnerabilities).

Also deleted

  • release-tweet.yml (we no longer send release tweets, this was never used)
  • merge-release-branch.yml (experiment to create a workflow to merge release into main after each release, doesn't fit into our process well as it requires creating a PR that must be approved)

Copy link

changeset-bot bot commented Mar 19, 2025

⚠️ No Changeset found

Latest commit: 96e9bff

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@google-oss-bot
Copy link
Contributor

@google-oss-bot
Copy link
Contributor

@hsubox76 hsubox76 marked this pull request as ready for review March 19, 2025 19:23
@hsubox76 hsubox76 requested a review from a team as a code owner March 19, 2025 19:23
Copy link
Contributor

@DellaBitta DellaBitta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you amend the PR description to include the fact that two workflows have been deleted?

@@ -42,10 +42,12 @@ jobs:
- uses: actions/setup-node@v4
with:
node-version: 22.10.0
- uses: 'google-github-actions/auth@v0'
# This commit represents v0.8.3
- uses: 'google-github-actions/auth@c4799db9111fba4461e9f9da8732e5057b394f72'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any reason why this one is in quotes?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was originally in quotes, didn't want to change it. I think both syntaxes are okay but the quotes are needed if there are special characters or something, so the original author was probably being careful.

@hsubox76
Copy link
Contributor Author

Could you amend the PR description to include the fact that two workflows have been deleted?

Added.

@hsubox76 hsubox76 merged commit 5718838 into main Mar 20, 2025
36 of 37 checks passed
@hsubox76 hsubox76 deleted the ch-gha-hashes branch March 20, 2025 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants