Clear the remaining zizmor findings in helm-publish - #6275
Merged
Conversation
Every expression in this workflow's run blocks is now bound through env:. The matrix and repository values move to a job-level env: since they are constant across the job; the chart version stays per-step, because job-level env: cannot read a step output. Both checkouts stop persisting credentials. Neither job here declares contents: write, so no push is possible and the credential has no use. None of these values could carry a shell metacharacter — the version is derived from the tag and the rest are matrix entries and a repository name — so this is consistency rather than a fix. It is worth doing now only because the workflow is otherwise clean and this keeps it that way. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6275 +/- ##
==========================================
+ Coverage 72.73% 72.76% +0.02%
==========================================
Files 742 742
Lines 77299 77299
==========================================
+ Hits 56224 56244 +20
+ Misses 17113 17076 -37
- Partials 3962 3979 +17 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Collaborator
Author
|
/retest |
10 tasks
rdimitrov
approved these changes
Aug 10, 2026
This was referenced Aug 10, 2026
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.
First of the follow-ups to #6274, which makes the zizmor check blocking at
medium. This clears the low and informational findings in one of the four release workflows so the threshold can eventually go lower.Summary
template-injectionfindings and bothartipackedfindings inhelm-publish.ymlare cleared — 11 → 0. Every expression in arun:block is now bound throughenv:.[A-Za-z0-9._-]. The genuinely reachable sinks in this file — the GHCR credentials and the unquotedhelm package --version— were fixed in Bind the GHCR credentials and chart version in helm-publish #6270. This is consistency, not a fix.It is worth doing now because the file is otherwise clean, so keeping it that way is cheap; and because leaving nine findings in place is what stops the gate dropping below
mediumlater.Shape
env:— they are constant across the job, so binding them once beats repeating them in six steps.CHART_VERSIONstays per-step, because job-levelenv:cannot read a step output. That is the one asymmetry and it is deliberate.$REGISTRYis referenced directly; it is already a workflow-levelenv:and so already in every step's shell.persist-credentials: false.Test plan
Unit tests (
task test)E2E tests (
task test-e2e)Linting (
task lint-fix)Manual testing (describe below)
Checked every shell variable in every step resolves. Wrote a check that collects each step's available names — workflow
env:, jobenv:, stepenv:, locally assigned, and the GitHub-provided ones — against every$VARit references. No step references anything undefined.Checked the artifact name still lines up.
helm packagewrites${CHART_NAME}-${CHART_VERSION}.tgzandhelm pushreads exactly that string; both now resolve from the same two variables rather than from re-interpolated expressions.Confirmed neither job can push —
verify-tagandpublish-helmboth declarecontents: read— sopersist-credentials: falsecannot break anything.Workflow parses as YAML;
actionlintclean;zizmorreports no findings at all for this file.This cannot be verified before merge.
helm-publish.ymlisworkflow_callonly, invoked fromreleaser.ymlonrelease: published, and it runs after the image push — a failure leaves images in GHCR and charts not. That risk has not changed; what has changed is that it is now being taken for tidiness rather than for a fix, which is worth weighing.Type of change
Does this introduce a user-facing change?
No.
Special notes for reviewers
mediumpermanently, which is a perfectly good place for it. Make the zizmor check blocking #6274 stands on its own either way.Package Helm chartstep keeps onlyCHART_VERSIONin itsenv:—CHART_PATHandCHART_NAMEnow come from the job — so that step's diff looks like a deletion. It is not losing anything.Generated with Claude Code