registry

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2021 License: MIT Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SaveChartPackage

func SaveChartPackage(ch *chart.Chart, dir string) (string, error)

Types

type Client

type Client struct {

	// TargetDir is the location where the downloaded chart is saved
	TargetDir string
	// contains filtered or unexported fields
}

func NewClient

func NewClient(l logr.InfoLogger, opts ...Option) (*Client, error)

NewClient is the constructor for the registry client

func (*Client) AddRepo added in v0.4.0

func (c *Client) AddRepo(cfg *Config) error

func (*Client) PullChart

func (c *Client) PullChart(l logr.Logger, repoKey, repoPath, chartName, version string) (string, *chart.Chart, error)

func (*Client) PushChart

func (c *Client) PushChart(l logr.Logger, repoKey, pkgPath string, ch *chart.Chart) error

PushChart pushes the chart to the repository specified by the repoKey. The repository setting is fetched from the associated registry config file

func (*Client) RegistryConfig added in v0.4.0

func (c *Client) RegistryConfig(name string) (*Config, error)

type Config

type Config struct {
	Name               string `yaml:"name" json:"name,omitempty"`
	URL                string `yaml:"url" json:"url,omitempty"`
	Username           string `yaml:"username" json:"username,omitempty"`
	Password           string `yaml:"password" json:"password,omitempty"`
	AuthHeader         string `yaml:"authHeader" json:"auth_header,omitempty"`
	CaFile             string `yaml:"caFile" json:"ca_file,omitempty"`
	CertFile           string `yaml:"certFile" json:"cert_file,omitempty"`
	KeyFile            string `yaml:"keyFile" json:"key_file,omitempty"`
	InsecureSkipVerify bool   `yaml:"insecureSkipVerify" json:"insecure_skip_verify,omitempty"`
	AccessToken        string `yaml:"accessToken" json:"access_token,omitempty"`
}

Config struct captures the configuration fields as per the repoAddOptions - https://github.com/helm/helm/blob/v3.1.2/cmd/helm/repo_add.go#L39

func GetHelmRepoConfig added in v0.4.0

func GetHelmRepoConfig(app *orkestrav1alpha1.Application, c client.Client) (*Config, error)

type CredentialsObjectReference added in v0.4.0

type CredentialsObjectReference struct {
	// Name of the referent
	Name string `yaml:"name" json:"name,omitempty"`

	// Namespace of the referent,
	Namespace string `yaml:"namespace" json:"namespace,omitempty"`
}

type Option

type Option func(c *Client)

func TargetDir

func TargetDir(d string) Option

type PullOption

type PullOption func(p *action.Pull)

Jump to

Keyboard shortcuts

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