[dmt] check helmignore root coverage#425
Open
diyliv wants to merge 1 commit into
Open
Conversation
aba7628 to
f953543
Compare
Signed-off-by: diyliv <onlogn081@gmail.com>
f953543 to
562db28
Compare
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.
Summary
.helmignoremust cover every file and directory in the module root, except the standard Helm chart template entries (templates/,charts/,Chart.yaml,values.yaml).helm.sh/helm/v3/pkg/ignorefor proper pattern matching (wildcards, negation, directory-only rules).pkg/linters/module/rules/helmignore.go,pkg/linters/module/rules/helmignore_test.go, e2e test fixtures.Context
When a new directory (e.g.
images/,hooks/) or file (e.g.go.mod,module.yaml) is added to a module root, developers often forget to add it to.helmignore. These files then leak into the Helm chart, increasing its size.The rule now scans the entire module root and flags any entry that is not covered by
.helmignore, except the four standard Helm template entries that must remain in the chart.Example
Before: module has
images/andgo.modbut.helmignoreonly listshooks/— no error.After:
Excluding resources