Repository navigation
Conversation
Pin actions/checkout to a commit, drop default token permissions, explain each job permission and name every job while keeping the socket-security check name. The ignore-command example now runs only for ignore commands. A test keeps the examples' action pins in step with the commits the repository's CI uses.
lelia
temporarily deployed
to
socket-firewall
November 24, 2026 05:07 — with
GitHub Actions
Inactive
The 171-line per-workspace workflow lived only in docs/ci-cd.md, where no linter checked it. It's now a template alongside the others, covered by actionlint, zizmor and the pin test, and the guide links to it.
This branch was successfully deployed
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.
Tightens the GitHub Actions examples added in 2.14.0 (#460), and moves the CI guide's monorepo workflow into a template of its own. Their structure is unchanged: one PR workflow that owns the required
socket-securitycheck, a push workflow for baselines, and an optional ignore-command workflow.Changes
actions/checkoutmoves from@v4to the commit for v7.0.1, the same commit the repository's own CI uses. The CI guide's inline examples get the same treatment:checkout,setup-pythonandcachewere floating on@v5,@v6and@v4.permissions: {}and grants per-job permissions, with a comment explaining each one. Every job has aname:. The PR job keepssocket-security, so branch protection doesn't change.socketdev/cli:latestso they stay current with every release, and a comment recommends pinning a release tag and digest for reproducible runs.@SocketSecurity ignorecommand, instead of starting a container for every comment. Theissue_commenttrigger stays, with the reason it's acceptable recorded next to it: the workflow never checks out PR code, and the CLI honors a command only from a commenter with write access.docs/ci-cd.md, where no linter checked it. It's nowworkflows/github-actions-monorepo.yml, an alternative to the PR workflow, and the guide links to it instead of inlining it. It gained named jobs and a concurrency group; its aggregatesocket-securitygate already ran withif: always()..github/workflowsbut notworkflows/or the docs, which is how the templates fell four majors behind. A new test fails when an example uses an unpinned action or a different commit than CI. It also checks that only the PR workflow and the monorepo alternative reportsocket-security, and that the monorepo gate always reports. When Dependabot bumps an action in CI, the test points to the examples that need the same change.Why still three files
Triggers are per file in GitHub Actions, and GitHub counts a skipped job as passing. So the required check needs a workflow whose only trigger is
pull_request. The push and ignore-command jobs could share a second file, but every PR would then show a skipped ignore-command check, and theissue_commenttrigger would move into the baseline workflow.What makes the split feel heavy is the repeated container, checkout and CLI boilerplate. Removing that needs a shared step that Socket hosts. A local composite action or reusable workflow would only add a fourth file for users to copy. The natural home is a Python CLI mode in SocketDev/action, which already has firewall, patch and CLI modes, or a reusable workflow in this repository. Either way, each template becomes a trigger plus one pinned step, but it means supporting a new interface, so it's left as a follow-up.
Verification
zizmor1.33.1, default and pedantic personas: no findings across all four templates. Before, the default persona reported 7 high findings and pedantic 15 in total. Four findings remain suppressed inline, each with its reason:latestin the three templates, and theissue_commenttrigger.actionlint: clean.main.ruff checkanduv lock --lockedpass.Release
This ships separately from 2.14.0. The branch bumps to 2.14.1 with its own changelog section, so merge it after 2.14.0 is published.
Public Changelog
The GitHub Actions examples pin their actions to commits, start with no token permissions, and pass
zizmor. The ignore-command example runs only for ignore commands. The CI guide explains re-running the required check after an ignore command.Fixes: CE-524