From 3e0e0798251061f7777e6f55829ca8db19b526fb Mon Sep 17 00:00:00 2001 From: pallam Date: Wed, 17 May 2023 15:24:21 +0300 Subject: [PATCH] fix(bundles/publish): fix usage of CreateNewBundle without env variables. Added common.Get* functions for usage in CreateNewBundle call --- cmd/werf/bundle/publish/publish.go | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/cmd/werf/bundle/publish/publish.go b/cmd/werf/bundle/publish/publish.go index f0964104f3..3b591eb2b2 100644 --- a/cmd/werf/bundle/publish/publish.go +++ b/cmd/werf/bundle/publish/publish.go @@ -15,6 +15,7 @@ import ( "helm.sh/helm/v3/pkg/cli/values" "github.com/werf/logboek" + "github.com/werf/werf/cmd/werf/common" "github.com/werf/werf/pkg/build" "github.com/werf/werf/pkg/config" @@ -408,10 +409,10 @@ func runPublish(ctx context.Context, imagesToProcess build.ImagesToProcess) erro defer os.RemoveAll(bundleTmpDir) bundle, err := wc.CreateNewBundle(ctx, bundleTmpDir, chartVersion, &values.Options{ - ValueFiles: *commonCmdData.Values, - StringValues: *commonCmdData.SetString, - Values: *commonCmdData.Set, - FileValues: *commonCmdData.SetFile, + ValueFiles: common.GetValues(&commonCmdData), + StringValues: common.GetSetString(&commonCmdData), + Values: common.GetSet(&commonCmdData), + FileValues: common.GetSetFile(&commonCmdData), }) if err != nil { return fmt.Errorf("unable to create bundle: %w", err)