fix(cmd): Specify namespace for template command

The template command uses the memory driver.  This driver now supports
namespaces, so the template code-path now specifies the namespace as
required by the memory driver.

Signed-off-by: Marc Khouzam <marc.khouzam@montreal.ca>
pull/7552/head
Marc Khouzam 6 years ago committed by Marc Khouzam
parent e6d2d10bad
commit be7de1c376

@ -187,7 +187,10 @@ func (i *Install) Run(chrt *chart.Chart, vals map[string]interface{}) (*release.
i.cfg.Capabilities = chartutil.DefaultCapabilities
i.cfg.Capabilities.APIVersions = append(i.cfg.Capabilities.APIVersions, i.APIVersions...)
i.cfg.KubeClient = &kubefake.PrintingKubeClient{Out: ioutil.Discard}
i.cfg.Releases = storage.Init(driver.NewMemory())
mem := driver.NewMemory()
mem.SetNamespace(i.Namespace)
i.cfg.Releases = storage.Init(mem)
} else if !i.ClientOnly && len(i.APIVersions) > 0 {
i.cfg.Log("API Version list given outside of client only mode, this list will be ignored")
}

Loading…
Cancel
Save