diff --git a/cmd/helm/install.go b/cmd/helm/install.go index 0e63ab3a5..f1c469f08 100644 --- a/cmd/helm/install.go +++ b/cmd/helm/install.go @@ -122,7 +122,7 @@ func newInstallCmd(cfg *action.Configuration, out io.Writer) *cobra.Command { return compInstall(args, toComplete, client) }, RunE: func(_ *cobra.Command, args []string) error { - rel, err := runInstall(args, client, valueOpts, out) + rel, err := runInstall(args, client, cfg, valueOpts, out) if err != nil { return errors.Wrap(err, "INSTALLATION FAILED") } @@ -174,7 +174,7 @@ func addInstallFlags(cmd *cobra.Command, f *pflag.FlagSet, client *action.Instal } } -func runInstall(args []string, client *action.Install, valueOpts *values.Options, out io.Writer) (*release.Release, error) { +func runInstall(args []string, client *action.Install, cfg *action.Configuration, valueOpts *values.Options, out io.Writer) (*release.Release, error) { debug("Original chart version: %q", client.Version) if client.Version == "" && client.Devel { debug("setting version to >0.0.0-0") @@ -227,6 +227,7 @@ func runInstall(args []string, client *action.Install, valueOpts *values.Options Keyring: client.ChartPathOptions.Keyring, SkipUpdate: false, Getters: p, + RegistryClient: cfg.RegistryClient, RepositoryConfig: settings.RepositoryConfig, RepositoryCache: settings.RepositoryCache, Debug: settings.Debug, diff --git a/cmd/helm/template.go b/cmd/helm/template.go index f9c51542a..5cd495b15 100644 --- a/cmd/helm/template.go +++ b/cmd/helm/template.go @@ -79,7 +79,7 @@ func newTemplateCmd(cfg *action.Configuration, out io.Writer) *cobra.Command { client.ClientOnly = !validate client.APIVersions = chartutil.VersionSet(extraAPIs) client.IncludeCRDs = includeCrds - rel, err := runInstall(args, client, valueOpts, out) + rel, err := runInstall(args, client, cfg, valueOpts, out) if err != nil && !settings.Debug { if rel != nil { diff --git a/cmd/helm/upgrade.go b/cmd/helm/upgrade.go index b856073c1..6a3f25d7c 100644 --- a/cmd/helm/upgrade.go +++ b/cmd/helm/upgrade.go @@ -118,7 +118,7 @@ func newUpgradeCmd(cfg *action.Configuration, out io.Writer) *cobra.Command { instClient.Description = client.Description instClient.DependencyUpdate = client.DependencyUpdate - rel, err := runInstall(args, instClient, valueOpts, out) + rel, err := runInstall(args, instClient, cfg, valueOpts, out) if err != nil { return err } @@ -159,6 +159,7 @@ func newUpgradeCmd(cfg *action.Configuration, out io.Writer) *cobra.Command { Keyring: client.ChartPathOptions.Keyring, SkipUpdate: false, Getters: p, + RegistryClient: cfg.RegistryClient, RepositoryConfig: settings.RepositoryConfig, RepositoryCache: settings.RepositoryCache, Debug: settings.Debug,