|
|
@ -211,7 +211,7 @@ func (i *Install) Run(chrt *chart.Chart, vals map[string]interface{}) (*release.
|
|
|
|
rel := i.createRelease(chrt, vals)
|
|
|
|
rel := i.createRelease(chrt, vals)
|
|
|
|
|
|
|
|
|
|
|
|
var manifestDoc *bytes.Buffer
|
|
|
|
var manifestDoc *bytes.Buffer
|
|
|
|
rel.Hooks, manifestDoc, rel.Info.Notes, err = i.cfg.renderResources(chrt, valuesToRender, i.OutputDir, i.SubNotes)
|
|
|
|
rel.Hooks, manifestDoc, rel.Info.Notes, err = i.cfg.renderResources(chrt, valuesToRender, i.OutputDir, i.SubNotes, i.ClientOnly)
|
|
|
|
// Even for errors, attach this if available
|
|
|
|
// Even for errors, attach this if available
|
|
|
|
if manifestDoc != nil {
|
|
|
|
if manifestDoc != nil {
|
|
|
|
rel.Manifest = manifestDoc.String()
|
|
|
|
rel.Manifest = manifestDoc.String()
|
|
|
@ -409,7 +409,7 @@ func (i *Install) replaceRelease(rel *release.Release) error {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// renderResources renders the templates in a chart
|
|
|
|
// renderResources renders the templates in a chart
|
|
|
|
func (c *Configuration) renderResources(ch *chart.Chart, values chartutil.Values, outputDir string, subNotes bool) ([]*release.Hook, *bytes.Buffer, string, error) {
|
|
|
|
func (c *Configuration) renderResources(ch *chart.Chart, values chartutil.Values, outputDir string, subNotes bool, clientOnly bool) ([]*release.Hook, *bytes.Buffer, string, error) {
|
|
|
|
hs := []*release.Hook{}
|
|
|
|
hs := []*release.Hook{}
|
|
|
|
b := bytes.NewBuffer(nil)
|
|
|
|
b := bytes.NewBuffer(nil)
|
|
|
|
|
|
|
|
|
|
|
@ -452,7 +452,7 @@ func (c *Configuration) renderResources(ch *chart.Chart, values chartutil.Values
|
|
|
|
// Sort hooks, manifests, and partials. Only hooks and manifests are returned,
|
|
|
|
// Sort hooks, manifests, and partials. Only hooks and manifests are returned,
|
|
|
|
// as partials are not used after renderer.Render. Empty manifests are also
|
|
|
|
// as partials are not used after renderer.Render. Empty manifests are also
|
|
|
|
// removed here.
|
|
|
|
// removed here.
|
|
|
|
hs, manifests, err := releaseutil.SortManifests(files, caps.APIVersions, releaseutil.InstallOrder)
|
|
|
|
hs, manifests, err := releaseutil.SortManifests(files, caps.APIVersions, releaseutil.InstallOrder, clientOnly)
|
|
|
|
if err != nil {
|
|
|
|
if err != nil {
|
|
|
|
// By catching parse errors here, we can prevent bogus releases from going
|
|
|
|
// By catching parse errors here, we can prevent bogus releases from going
|
|
|
|
// to Kubernetes.
|
|
|
|
// to Kubernetes.
|
|
|
|