Add --helm-debug Flag to Kustomize for Enhanced Helm Debugging (#5751)

* feat: add helm-debug flag

* revert: go.work.sum

* test: add helm chart args helm-debug test

* test: helm debug flag

* refactor: helm debug output

* style: linting

* revert: go.work.sum
This commit is contained in:
Isar_NS
2024-09-13 01:43:12 +03:00
committed by GitHub
parent c3872ce3d9
commit 4034e36ee1
8 changed files with 83 additions and 2 deletions

View File

@@ -96,6 +96,9 @@ type HelmChart struct {
// SkipTests skips tests from templated output.
SkipTests bool `json:"skipTests,omitempty" yaml:"skipTests,omitempty"`
// debug enables debug output from the Helm chart inflator generator.
Debug bool `json:"debug,omitempty" yaml:"debug,omitempty"`
}
// HelmChartArgs contains arguments to helm.
@@ -188,5 +191,8 @@ func (h HelmChart) AsHelmArgs(absChartHome string) []string {
if h.SkipHooks {
args = append(args, "--no-hooks")
}
if h.Debug {
args = append(args, "--debug")
}
return args
}