From 189bc43112d1c1a07b342922c8363fc087b12ac7 Mon Sep 17 00:00:00 2001 From: Matt Butcher Date: Tue, 29 Nov 2016 16:58:55 -0700 Subject: [PATCH] fix(helm): pass the no-hooks flag during upgrade Helm upgrades were not passing the no-hooks value to the server. Closes #1590 --- cmd/helm/upgrade.go | 7 ++++++- pkg/helm/client.go | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/cmd/helm/upgrade.go b/cmd/helm/upgrade.go index 076b57ca5..d55a8013f 100644 --- a/cmd/helm/upgrade.go +++ b/cmd/helm/upgrade.go @@ -135,7 +135,12 @@ func (u *upgradeCmd) run() error { return err } - _, err = u.client.UpdateRelease(u.release, chartPath, helm.UpdateValueOverrides(rawVals), helm.UpgradeDryRun(u.dryRun), helm.UpgradeDisableHooks(u.disableHooks)) + _, err = u.client.UpdateRelease( + u.release, + chartPath, + helm.UpdateValueOverrides(rawVals), + helm.UpgradeDryRun(u.dryRun), + helm.UpgradeDisableHooks(u.disableHooks)) if err != nil { return fmt.Errorf("UPGRADE FAILED: %v", prettyError(err)) } diff --git a/pkg/helm/client.go b/pkg/helm/client.go index a39b8c170..5ae781328 100644 --- a/pkg/helm/client.go +++ b/pkg/helm/client.go @@ -132,6 +132,7 @@ func (h *Client) UpdateRelease(rlsName string, chstr string, opts ...UpdateOptio req.Chart = chart req.DryRun = h.opts.dryRun req.Name = rlsName + req.DisableHooks = h.opts.disableHooks ctx := NewContext() if h.opts.before != nil {