-
Notifications
You must be signed in to change notification settings - Fork 21
Harden CI/CD pipeline #40
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
Conversation
Grub4K
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
idc
| deno-version: v2.x | ||
| - uses: actions/setup-python@v6 | ||
| cache: false | ||
| - uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We will have to think about this, see https://api.github.com/repos/actions/python-versions/releases/tags/3.15.0-alpha.2-19505847594 the release is not immutable, though I think it would be hard to actually make this work otherwise. I'm willing to take that risk for now
This pull request adds a zizmor audit of GHA workflows via zizmor-action.
Many of the changes in this PR are to comply with zizmor's audit rules, including:
Pin all actions to commit hashes instead of symbolic references
Explicitly set
GITHUB_TOKENpermissions at the job levelAdd explanatory comments to
permissions:blocks for any permission besidescontents: readUse
actions/checkoutwithpersist-credentials: falsewhenever possibleSet a
namefor all job definitionsRemove all usage of
actions/cachefrom our release pipelineIn addition, there are some changes unrelated to the zizmor audit rules:
Explicitly set
shell: bashfor several steps, either to avoidpwshon Windows runners or to ensure thatpipefailis set (since it is not set without an explicitshell: bash)Set
$ErrorActionPreferenceto"Stop"and$PSNativeCommandUseErrorActionPreferenceto$truein allpwshcode contexts to ensure the steps will fail on non-zero exit codesRename the
ruff-lintandruff-formatjobs toruff_lintandruff_formatfor consistency