Skip to content

feat: Add support for the non-default namespace for the targeted release #85

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

Merged
merged 1 commit into from
Aug 27, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion cmd/upgrade.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ type diffCmd struct {
chartVersion string
client helm.Interface
detailedExitCode bool
namespace string // namespace to assume the release to be installed into. Defaults to the current kube config namespace.
valueFiles valueFiles
values []string
reuseValues bool
Expand Down Expand Up @@ -77,6 +78,7 @@ func newChartCommand() *cobra.Command {
f.BoolVar(&diff.allowUnreleased, "allow-unreleased", false, "enables diffing of releases that are not yet deployed via Helm")
f.StringArrayVar(&diff.suppressedKinds, "suppress", []string{}, "allows suppression of the values listed in the diff output")
f.IntVarP(&diff.outputContext, "context", "C", -1, "output NUM lines of context around changes")
f.StringVar(&diff.namespace, "namespace", "default", "namespace to assume the release to be installed into")

addCommonCmdOptions(f)

Expand Down Expand Up @@ -121,7 +123,7 @@ func (d *diffCmd) run() error {
if newInstall {
installResponse, err := d.client.InstallRelease(
chartPath,
"default",
d.namespace,
helm.ReleaseName(d.release),
helm.ValueOverrides(rawVals),
helm.InstallDryRun(true),
Expand Down