chartresolver

package
v0.109.0 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2024 License: Apache-2.0 Imports: 36 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MaxSizeInByteDefault          = 100 * 1000 * 1000
	RemoveOutdatedDurationDefault = time.Hour * 24
)

Variables

View Source
var NoChartDefinedError = errors.New("no chart was provided")

NoChartDefinedError is the error that is returned if no Helm chart was provided

Functions

func GetChart

func GetChart(ctx context.Context,
	chartConfig *helmv1alpha1.Chart,
	lsClient client.Client,
	contextObj *lsv1alpha1.Context,
	registryPullSecrets []corev1.Secret,
	ociConfig *config.OCIConfiguration,
	useChartCache bool) (*chart.Chart, error)

GetChart resolves the chart based on a chart access configuration.

func MarshalChart added in v0.105.0

func MarshalChart(chart *chart.Chart) ([]byte, error)

func UnmarshalChart added in v0.105.0

func UnmarshalChart(bytes []byte) (*chart.Chart, error)

Types

type ChartTree added in v0.105.0

type ChartTree struct {
	Chart    *chart.Chart `json:"chart,omitempty"`
	SubTrees []*ChartTree `json:"subTrees,omitempty"`
}

ChartTree is a tree containing a chart and its subcharts (recursively), both in public fields so that they are respected during marshaling.

type HelmChartCache added in v0.104.0

type HelmChartCache struct {
	// contains filtered or unexported fields
}

func GetHelmChartCache added in v0.104.0

func GetHelmChartCache(initMaxSizeInByte int64, initRemoveOutdatedDuration time.Duration) *HelmChartCache

func (*HelmChartCache) Clear added in v0.104.0

func (c *HelmChartCache) Clear()

func (*HelmChartCache) GetEntries added in v0.104.0

func (c *HelmChartCache) GetEntries() (map[string]*cacheEntry, int64, time.Time)

func (*HelmChartCache) HasKey added in v0.104.0

func (c *HelmChartCache) HasKey(ociRef string, helmRepo *helmv1alpha1.HelmChartRepo, ocmKey string) (bool, error)

func (*HelmChartCache) SetLastCleanup added in v0.104.0

func (c *HelmChartCache) SetLastCleanup(lastCleanup time.Time)

func (*HelmChartCache) SetMaxSizeInByte added in v0.104.0

func (c *HelmChartCache) SetMaxSizeInByte(maxSizeInByte int64)

func (*HelmChartCache) SetOutdatedDuration added in v0.104.0

func (c *HelmChartCache) SetOutdatedDuration(removeOutdatedDuration time.Duration)

Jump to

Keyboard shortcuts

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