helper

package
v1.13.2 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: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetCSVName

func GetCSVName(csv yaml.MapSlice) string

GetCSVName -retrieves CSV name from provided CSV manifest

func GetCSVVersion

func GetCSVVersion(csv yaml.MapSlice) string

GetCSVVersion - retrievs CSV Version from provided CSV manifest

Types

type Bundle

type Bundle struct {
	Data Data `yaml:"data"`
}

Bundle - OLM bundle

type BundleHelper

type BundleHelper struct {
	Pkgs []Pkg
	CRDs []v1beta1.CustomResourceDefinition
	CSVs []yaml.MapSlice
	// contains filtered or unexported fields
}

BundleHelper - object that provides logic of fetching OLM bundle from marketplace quay repo

func NewBundleHelper

func NewBundleHelper(repo, namespace string) (*BundleHelper, error)

NewBundleHelper - Ctor

func (*BundleHelper) AddOldManifests

func (bh *BundleHelper) AddOldManifests(outDir string, currentCSVVersion string) error

AddOldManifests - downloads old CRDs and CSVs to outDir with respect to currentCSVVersion

func (*BundleHelper) GetLatestPublishedCSVVersion

func (bh *BundleHelper) GetLatestPublishedCSVVersion() string

GetLatestPublishedCSVVersion - return latest CSV version that exists in quay

func (*BundleHelper) VerifyNotPublishedCSVVersion

func (bh *BundleHelper) VerifyNotPublishedCSVVersion(currentCSVVersion string) bool

VerifyNotPublishedCSVVersion - returns latest CSV version that exists

type Channel

type Channel struct {
	Name       string `yaml:"name"`
	CurrentCSV string `yaml:"currentCSV"`
}

Channel from which OLM bundle is consumed

type Data

type Data struct {
	CSVs     string `yaml:"clusterServiceVersions"`
	CRDs     string `yaml:"customResourceDefinitions"`
	Packages string `yaml:"packages"`
}

Data - OLM bundle wrapper

type Pkg

type Pkg struct {
	PkgName  string    `yaml:"packageName"`
	Channels []Channel `yaml:"channels"`
}

Pkg - Package to be consumed

Jump to

Keyboard shortcuts

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