driver

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2023 License: Apache-2.0 Imports: 35 Imported by: 2

Documentation

Index

Constants

View Source
const AppReleasesDriverName = "drivers.x-helm.dev/appreleases"

AppReleasesDriverName is the string name of the driver.

Variables

This section is empty.

Functions

func ParseKey

func ParseKey(key string) (string, int, error)

ParseKey returns release name and version from a key generated by makeKey. ref: https://github.com/helm/helm/blob/241785c70fb38b2c074d7b3ddf0925812fb3fc69/pkg/storage/storage.go#L242-L250

func ResourceFilename

func ResourceFilename(apiVersion, kind, chartName, name string) (string, string, string)

func ResourceKey

func ResourceKey(apiVersion, kind, chartName, name string) (string, error)

Types

type AppReleases added in v0.6.0

type AppReleases struct {
	Log func(string, ...interface{})
	// contains filtered or unexported fields
}

AppReleases is a wrapper around an implementation of a kubernetes AppReleasesInterface.

func NewAppReleases added in v0.6.0

func NewAppReleases(ai client.Client) *AppReleases

NewAppReleases initializes a new AppReleases wrapping an implementation of the kubernetes AppReleasesInterface.

func (*AppReleases) Create added in v0.6.0

func (d *AppReleases) Create(_ string, rls *rspb.Release) error

Create creates a new AppRelease holding the release. If the AppRelease already exists, ErrReleaseExists is returned.

func (*AppReleases) Delete added in v0.6.0

func (d *AppReleases) Delete(key string) (rls *rspb.Release, err error)

Delete deletes the AppRelease holding the release named by key.

func (*AppReleases) Get added in v0.6.0

func (d *AppReleases) Get(key string) (*rspb.Release, error)

Get fetches the release named by key. The corresponding release is returned or error if not found.

func (*AppReleases) List added in v0.6.0

func (d *AppReleases) List(filter func(*rspb.Release) bool) ([]*rspb.Release, error)

List fetches all releases and returns the list releases such that filter(release) == true. An error is returned if the configmap fails to retrieve the releases.

func (*AppReleases) Name added in v0.6.0

func (d *AppReleases) Name() string

Name returns the name of the driver.

func (*AppReleases) Query added in v0.6.0

func (d *AppReleases) Query(labels map[string]string) ([]*rspb.Release, error)

Query fetches all releases that match the provided map of labels. An error is returned if the configmap fails to retrieve the releases.

func (*AppReleases) Update added in v0.6.0

func (d *AppReleases) Update(_ string, rls *rspb.Release) error

Update updates the AppRelease holding the release. If not found the AppRelease is created to hold the release.

type EditorTemplate

type EditorTemplate struct {
	Manifest []byte                     `json:"manifest,omitempty"`
	Values   *unstructured.Unstructured `json:"values,omitempty"`
}

Jump to

Keyboard shortcuts

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