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

GitHub Actions should be referenced by SHA not tag #208

Open
stevehipwell opened this issue Jan 19, 2023 · 3 comments
Open

GitHub Actions should be referenced by SHA not tag #208

stevehipwell opened this issue Jan 19, 2023 · 3 comments

Comments

@stevehipwell
Copy link

Just like how container images should be referenced by digest, GitHub actions should be referenced by SHA and not tag. Dependabot can handle this pattern including keeping the tag used next to the SHA as a comment.

jobs:
  test:
    steps:
      - name: Checkout
        uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0
@imjasonh
Copy link
Member

I realize I'm pretty late to this, but I agree FWIW.

This repo doesn't do tagged releases, since it would be pretty disruptive to get dependabot updates for each action when only one action had a meaningful release. Having a bunch of single-action individually-tagged repos proliferate around also sounds pretty annoying, to be honest.

In the absence of releases, consumers should reference actions by SHA instead of @main. The issue now is clearly and concretely updating all the docs to encourage this, instead of @main as today.

@stevehipwell
Copy link
Author

Having a bunch of single-action individually-tagged repos proliferate around also sounds pretty annoying, to be honest.

Isn't this the Unix philosophy and exactly what Dependabot is designed to handle? IMHO this would be significantly less complex than dealing with SHAs directly, especially to figure out if a subfolder action needed it reference changing.

My personal, and I thought widely acknowledged, opinion is that monorepos work where the tooling and integrations can be engineered as one. For repos hosting GitHub Actions this isn't the case (currently) and as such attempting to use a monorepo is going to be fighting against the system instead of working with it.

@xnox
Copy link
Contributor

xnox commented May 21, 2024

In the absence of releases, consumers should reference actions by SHA instead of @main. The issue now is clearly and concretely updating all the docs to encourage this, instead of @main as today.

this has inverse problem that dependabot does not know how to update such SHA of the branch. Could we at least make digestbot be able to update SHA of github actions branches?

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

No branches or pull requests

3 participants