feat(helm): add ability for --dry-run to do lookup functions

When a helm command is run with the --dry-run flag, it will try to connect to the cluster
if the value is 'server' to be able to render lookup functions.
Closes #8137

Signed-off-by: Tapas Kapadia <tapaskapadia10@gmail.com>
pull/9426/head
Tapas Kapadia 2 years ago
parent 9a0025f963
commit 25ac62e153

@ -211,7 +211,7 @@ func (i *Install) RunWithContext(ctx context.Context, chrt *chart.Chart, vals ma
var interactWithRemote bool var interactWithRemote bool
// `helm template` is the only command that Install.APIVersions field will not be nil. // `helm template` is the only command that Install.APIVersions field will not be nil.
if (!i.DryRun || i.DryRunOption == "server") && i.APIVersions == nil { if !i.DryRun || i.DryRunOption == "server" {
interactWithRemote = true interactWithRemote = true
} }

Loading…
Cancel
Save