helm

package
v1.7.4-rc.0 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2020 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// The default URL for getting the charts listing
	DefaultHelmRepoURL = "https://www.getambassador.io"

	// The default chart name
	DefaultChartName = "ambassador"
)

Variables

View Source
var (
	// ErrUnknownHelmRepoScheme is unknown helm repo scheme
	ErrUnknownHelmRepoScheme = errors.New("unknown helm repo scheme")

	// ErrNoChartDirFound is no chart directory found
	ErrNoChartDirFound = errors.New("no chart directory found")
)

Functions

func Equal

func Equal(a, b string) (bool, error)

Equal returns True if a is equal to b

func MoreRecentThan

func MoreRecentThan(a, b string) (bool, error)

MoreRecentThan returns True if a is more recent than b

Types

type ChartVersionRule

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

A chart version rule defines the rules for allowed chart versions

func NewChartVersionRule

func NewChartVersionRule(ver string) (ChartVersionRule, error)

func (ChartVersionRule) Allowed

func (cv ChartVersionRule) Allowed(s string) (bool, error)

Allowed returns true if the version provided is allowed by the ChartVersionRule

func (ChartVersionRule) String

func (cv ChartVersionRule) String() string

type HelmDownloader

type HelmDownloader struct {
	URL     *url.URL
	Version ChartVersionRule

	KubeInfo *k8s.KubeInfo

	DownChartDir string
	// contains filtered or unexported fields
}

HelmDownloader is a downloader for a remote Helm repo or a file, provided with an URL

func NewHelmDownloader

func NewHelmDownloader(options HelmDownloaderOptions) (HelmDownloader, error)

NewHelmDownloader creates a new charts manager The Helm Manager will use the URL provided, and download (lazily) a Chart that obeys the Version Rule.

func (*HelmDownloader) Cleanup

func (lc *HelmDownloader) Cleanup() error

Cleanup removed all the download directories

func (*HelmDownloader) Download

func (lc *HelmDownloader) Download() error

GetReleaseMgr returns a manager for the latest

func (*HelmDownloader) FindLatestVersionAvailable added in v1.5.0

func (lc *HelmDownloader) FindLatestVersionAvailable() (string, error)

FindLatestVersionAvailable returns the latest version available in the repository (or file) specified in the `helmRepo`.

func (HelmDownloader) GetChart

func (lc HelmDownloader) GetChart() *chart.Metadata

GetChart returns the metadata about the Chart that has been downloaded from URL with the given constraints (like the Version)

func (HelmDownloader) GetVersionRule

func (lc HelmDownloader) GetVersionRule() ChartVersionRule

GetValues returns the version rules associated with this Helm manager

func (*HelmDownloader) Install

func (lc *HelmDownloader) Install(namespace string, values map[string]interface{}) (*release.Release, error)

type HelmDownloaderOptions

type HelmDownloaderOptions struct {
	URL      string
	KubeInfo *k8s.KubeInfo
	Version  ChartVersionRule
	Logger   *log.Logger
}

HelmDownloaderOptions specifies options for creating the Helm manager

Jump to

Keyboard shortcuts

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