Skip to content

fix: honor --release-name instead of generating a random release name#841

Open
somaz94 wants to merge 1 commit into
helm:mainfrom
somaz94:fix-198-release-name
Open

fix: honor --release-name instead of generating a random release name#841
somaz94 wants to merge 1 commit into
helm:mainfrom
somaz94:fix-198-release-name

Conversation

@somaz94
Copy link
Copy Markdown

@somaz94 somaz94 commented Jun 4, 2026

What this PR does / why we need it:

ct install --release-name <name> was ignored. Chart.CreateInstallParams only honored the release name when the chart path resolved to . or /, and unconditionally appended a random suffix — so --release-name go-backend still produced helm install go-backend-<random> (see the reproduction in the issue). This uses the provided --release-name verbatim as the release name (Helm validates the syntax). The namespace derivation is unchanged.

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #198

Special notes for your reviewer:

  • New unit test TestChart_CreateInstallParams in pkg/chart/chart_test.go (fails before the fix: the release came out as simple-deployment-<random> instead of my-release).
  • go test ./..., go vet ./pkg/chart/, gofmt -l, and golangci-lint run ./pkg/chart/... are all clean locally.
  • Namespace behavior is intentionally unchanged: with --namespace go-backend --release-name go-backend the caller now yields helm install go-backend --namespace go-backend.

@somaz94
Copy link
Copy Markdown
Author

somaz94 commented Jun 5, 2026

Gentle ping 🙏 — green and ready for review. This makes ct install honor an explicit --release-name instead of always generating a random one (also fixes the behavior reported in helm/chart-testing-action#198). Happy to address any feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

install --upgrade delete namespace at end of previous version install

1 participant