chart

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2023 License: Apache-2.0 Imports: 31 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AppendContainersFlags added in v0.0.3

func AppendContainersFlags(flags map[string]interface{}, publisherURL, traceCollectorURL string) map[string]interface{}

func BuildFlags added in v0.0.3

func BuildFlags(ctx context.Context, client client.Client, serverless *v1alpha1.Serverless) (map[string]interface{}, error)

build flags for the installation. The Serverless resource should be validated and ready to use

func CheckCRDOrphanResources

func CheckCRDOrphanResources(config *Config) error

func Install

func Install(config *Config) error

func Uninstall

func Uninstall(config *Config, filterFunc ...FilterFunc) error

func Verify

func Verify(config *Config) (bool, error)

func WithoutCRDFilter

func WithoutCRDFilter(u unstructured.Unstructured) bool

Types

type Cluster

type Cluster struct {
	Client client.Client
	Config *rest.Config
}

type Config

type Config struct {
	Ctx     context.Context
	Log     *zap.SugaredLogger
	Cache   *ManifestCache
	Cluster Cluster
	Release Release
}

type FilterFunc

type FilterFunc func(unstructured.Unstructured) bool

type ManifestCache

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

ManifestCache provides an in-memory processor to store serverless Spec and rendered chart manifest. By using sync.Map for caching, concurrent operations to the processor from diverse reconciliations are considered safe.

Inside the processor is stored chart manifest with used custom flags by client.ObjectKey key.

func NewManifestCache

func NewManifestCache() *ManifestCache

NewManifestCache returns a new instance of ManifestCache.

func (*ManifestCache) Delete

func (r *ManifestCache) Delete(key client.ObjectKey)

DeleteProcessor deletes flags and manifest from ManifestCache for the passed client.ObjectKey.

func (*ManifestCache) Get

Get loads the ServerlessSpecManifest from ManifestCache for the passed client.ObjectKey.

func (*ManifestCache) Set

func (r *ManifestCache) Set(key client.ObjectKey, customFlags map[string]interface{}, manifest string)

SetProcessor saves the passed flags and manifest into ManifestCache for the client.ObjectKey.

type Release

type Release struct {
	Flags     map[string]interface{}
	ChartPath string
	Name      string
	Namespace string
}

type ServerlessSpecManifest

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

Jump to

Keyboard shortcuts

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