manifest

package
v0.0.1-0...-c643c2e Latest Latest
Warning

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

Go to latest
Published: May 29, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Save

func Save(mf Manifest, filename string) error

Save writes the given manifest as yaml to the given filename.

Types

type Builder

type Builder struct {
	Kind      string   `yaml:"type"`
	Packages  []string `yaml:"packages"`
	Bundle    string   `yaml:"bundle,omitempty"`
	NodeIndex int      `yaml:"nodeIndex,omitempty"`
	Image     string   `yaml:"image,omitempty"`
}

Builder represents a single builder configuration. This captures all kernel versions that can be produced by the given type.

type ImageThreshold

type ImageThreshold struct {
	KernelVersion string
	ImageName     string
}

type Manifest

type Manifest map[string]Builder

Manifest represents a map of Builder instances.

func Combine

func Combine(caches ...Manifest) Manifest

Combine aggregates all of the given manifests together into one single manifest.

func CombineDir

func CombineDir(directory string) (Manifest, error)

CombineDir aggregates all of the manifest .yml files inside of the given directory together into one single manifest.

func CombineFiles

func CombineFiles(filenames []string) (Manifest, error)

CombineFiles aggregates all of the given manifest files together into one single manifest.

func Load

func Load(filename string) (Manifest, error)

Load reads the given filename as yaml and parses the content into a list of Manifest.

func New

func New() Manifest

New returns an initialized builder

func (Manifest) Add

func (m Manifest) Add(kind string, packages []string)

Adds a Builder with the given kind and packages to the Manifest under an id derived by checksumming the given set of packages.

func (Manifest) AddBuilder

func (m Manifest) AddBuilder(builder Builder)

Adds a Builder to the Manifest under an id derived by checksumming the set of packages in the Builder.

func (Manifest) SortedIDs

func (m Manifest) SortedIDs() []string

SortedIDs returns a list of all manifest ids, sorted in alphabetical order.

Jump to

Keyboard shortcuts

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