From 9465ce979b1c03f8e2470688328e2e2b4314418c Mon Sep 17 00:00:00 2001 From: Michelle Noorali Date: Sun, 7 Aug 2016 21:29:05 -0600 Subject: [PATCH] chore(helm): add options to update request --- pkg/helm/option.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pkg/helm/option.go b/pkg/helm/option.go index 98a6efc19..efd4c390e 100644 --- a/pkg/helm/option.go +++ b/pkg/helm/option.go @@ -238,8 +238,15 @@ func (o *options) rpcDeleteRelease(rlsName string, rlc rls.ReleaseServiceClient, // Executes tiller.UpdateRelease RPC. func (o *options) rpcUpdateRelease(rlsName string, chr *cpb.Chart, rlc rls.ReleaseServiceClient, opts ...UpdateOption) (*rls.UpdateReleaseResponse, error) { //TODO: handle dryRun + for _, opt := range opts { + opt(o) + } + + o.updateReq.Chart = chr + o.updateReq.DryRun = o.dryRun + o.updateReq.Name = rlsName - return rlc.UpdateRelease(context.TODO(), &rls.UpdateReleaseRequest{Name: rlsName, Chart: chr}) + return rlc.UpdateRelease(context.TODO(), &o.updateReq) } // Executes tiller.GetReleaseStatus RPC.