chart

package
v1.60.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 15, 2022 License: Apache-2.0, BSD-2-Clause, MIT, + 1 more Imports: 8 Imported by: 92

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InjectImages

func InjectImages(values map[string]interface{}, v imagevector.ImageVector, names []string, opts ...imagevector.FindOptionFunc) (map[string]interface{}, error)

InjectImages finds the images with the given names and opts, makes a shallow copy of the given Values and injects a name to image string mapping at the `images` key of that map and returns it.

Types

type Chart

type Chart struct {
	Name      string
	Path      string
	Images    []string
	Objects   []*Object
	SubCharts []*Chart
}

Chart represents a Helm chart (and its sub-charts) that can be applied and deleted.

func (*Chart) Apply

func (c *Chart) Apply(
	ctx context.Context,
	chartApplier gardenerkubernetes.ChartApplier,
	namespace string,
	imageVector imagevector.ImageVector,
	runtimeVersion, targetVersion string,
	additionalValues map[string]interface{},
) error

Apply applies this chart in the given namespace using the given ChartApplier. Before applying the chart, it collects its values, injecting images and merging the given values as needed.

func (*Chart) Delete

func (c *Chart) Delete(ctx context.Context, client client.Client, namespace string) error

Delete deletes this chart's objects from the given namespace using the given client.

func (*Chart) Render

func (c *Chart) Render(
	chartRenderer chartrenderer.Interface,
	namespace string,
	imageVector imagevector.ImageVector,
	runtimeVersion, targetVersion string,
	additionalValues map[string]interface{},
) (string, []byte, error)

Render renders this chart in the given namespace using the given chartRenderer. Before rendering the chart, it collects its values, injecting images and merging the given values as needed.

type Interface added in v1.8.0

type Interface interface {
	// Apply applies this chart in the given namespace using the given ChartApplier. Before applying the chart,
	// it collects its values, injecting images and merging the given values as needed.
	Apply(context.Context, gardenerkubernetes.ChartApplier, string, imagevector.ImageVector, string, string, map[string]interface{}) error
	// Render renders this chart in the given namespace using the given chartRenderer. Before rendering the chart,
	// it collects its values, injecting images and merging the given values as needed.
	Render(chartrenderer.Interface, string, imagevector.ImageVector, string, string, map[string]interface{}) (string, []byte, error)
	// Delete deletes this chart's objects from the given namespace.
	Delete(context.Context, client.Client, string) error
}

Interface represents a Helm chart that can be applied and deleted.

type Object

type Object struct {
	Type client.Object
	Name string
}

Object represents an object deployed by a Chart.

func (*Object) Delete

func (o *Object) Delete(ctx context.Context, c client.Client, namespace string) error

Delete deletes this object from the given namespace using the given client.

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL