Skip to content

ci: add Dependabot and pin all Actions to commit SHAs#12

Merged
Ti-03 merged 2 commits into
mainfrom
ci/dependabot-and-sha-pins
Jul 24, 2026
Merged

ci: add Dependabot and pin all Actions to commit SHAs#12
Ti-03 merged 2 commits into
mainfrom
ci/dependabot-and-sha-pins

Conversation

@Ti-03

@Ti-03 Ti-03 commented Jul 21, 2026

Copy link
Copy Markdown
Owner

What

  • .github/dependabot.yml: weekly update PRs for both the swift package ecosystem and github-actions.
  • Pin every uses: in ci.yml and pages.yml to the resolved commit SHA of its current tag, keeping the version as a trailing # vN comment.

Why

Week 7 (Security & the Software Supply Chain), task 1. A mutable tag like @v4 can be re-pointed after a compromise of the action's repo (the 2024 tj-actions/changed-files incident); a commit SHA can't. Dependabot understands the # vN comment convention and keeps both the SHA and comment current, so the pins don't rot.

How

SHAs resolved via the GitHub API from each action's current tag:

  • actions/checkout@v4 → 11d5960a
  • actions/cache@v4 → 0057852b
  • actions/setup-python@v5 → a26af69b
  • actions/upload-pages-artifact@v3 → 56afc609
  • actions/deploy-pages@v4 → d6db9016

Test

Workflows are YAML-valid; the CI matrix on this PR itself exercises the pinned checkout/cache actions.

Ti-03 added 2 commits July 22, 2026 00:08
…mmit SHAs

A mutable tag like @v4 can be re-pointed; anyone who compromises the
action repo can silently change what runs in this CI. Pinning to the
resolved commit SHA freezes the exact code, and Dependabot's
github-actions ecosystem keeps the pins (and the # vN comments) updated
via PRs. The swift ecosystem does the same for SwiftPM dependencies.
.github/styles/ is generated by 'vale sync' in CI and stays untracked,
per the Vale setup in PR #10.
@Ti-03
Ti-03 merged commit 939c497 into main Jul 24, 2026
2 checks passed
@Ti-03
Ti-03 deleted the ci/dependabot-and-sha-pins branch July 24, 2026 07:11
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.

1 participant