pull

package
v1.13.8 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2020 License: Apache-2.0 Imports: 33 Imported by: 14

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrSignatureInvalid = errors.New("signature is invalid")
	ErrSignatureMissing = errors.New("signature is missing")
)

Functions

func CanPullUpstream added in v0.9.0

func CanPullUpstream(upstreamURI string, pullOptions PullOptions) (bool, error)

CanPullUpstream will return a bool indicating if the specified upstream is accessible and authenticated for us.

func GetAppPublicKey added in v1.7.0

func GetAppPublicKey(license *kotsv1beta1.License) ([]byte, error)

func GetUpdates

func GetUpdates(upstreamURI string, getUpdatesOptions GetUpdatesOptions) ([]upstream.Update, error)

GetUpdates will retrieve all later versions of the application specified in upstreamURI using the options specified in getUpdatesOptions. It returns a list of versions.

func Pull

func Pull(upstreamURI string, pullOptions PullOptions) (string, error)

Pull will download the application specified in upstreamURI using the options specified in pullOptions. It returns the directory that the app was pulled to

func PullApplicationMetadata

func PullApplicationMetadata(upstreamURI string) ([]byte, error)

PullApplicationMetadata will return the application metadata yaml, if one is available for the upstream

func RewriteUpstream

func RewriteUpstream(upstreamURI string) string

func VerifyOldSignature added in v1.2.0

func VerifyOldSignature(license *kotsv1beta1.License) (*kotsv1beta1.License, error)

func VerifySignature added in v1.1.0

func VerifySignature(license *kotsv1beta1.License) (*kotsv1beta1.License, error)

Types

type GetUpdatesOptions

type GetUpdatesOptions struct {
	HelmRepoURI    string
	Namespace      string
	LocalPath      string
	LicenseFile    string
	CurrentCursor  string
	CurrentChannel string
	Silent         bool
}

type InnerSignature added in v1.2.0

type InnerSignature struct {
	LicenseSignature []byte `json:"licenseSignature"`
	PublicKey        string `json:"publicKey"`
	KeySignature     []byte `json:"keySignature"`
}

type KeySignature added in v0.9.15

type KeySignature struct {
	Signature   []byte `json:"signature"`
	GlobalKeyId string `json:"globalKeyId"`
}

type OuterSignature added in v1.2.0

type OuterSignature struct {
	LicenseData    []byte `json:"licenseData"`
	InnerSignature []byte `json:"innerSignature"`
}

type PullOptions

type PullOptions struct {
	HelmRepoURI         string
	RootDir             string
	Namespace           string
	Downstreams         []string
	LocalPath           string
	LicenseFile         string
	InstallationFile    string
	AirgapRoot          string
	ConfigFile          string
	UpdateCursor        string
	ExcludeKotsKinds    bool
	ExcludeAdminConsole bool
	SharedPassword      string
	CreateAppDir        bool
	Silent              bool
	RewriteImages       bool
	RewriteImageOptions RewriteImageOptions
	HelmOptions         []string
	ReportWriter        io.Writer
}

type RewriteImageOptions

type RewriteImageOptions struct {
	ImageFiles string
	Host       string
	Namespace  string
	Username   string
	Password   string
}

Jump to

Keyboard shortcuts

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