types

package
v0.20.0 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2024 License: AGPL-3.0 Imports: 2 Imported by: 3

Documentation

Overview

Package types contains all the types used by UDS.

Package types contains all the types used by UDS.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BundleChartOverrides

type BundleChartOverrides struct {
	Values      []BundleChartValue    `json:"values,omitempty" jsonschema:"description=List of Helm chart values to set statically"`
	Variables   []BundleChartVariable `json:"variables,omitempty" jsonschema:"description=List of Helm chart variables to set via UDS variables"`
	Namespace   string                `json:"namespace,omitempty" jsonschema:"description=The namespace to deploy the Helm chart to"`
	ValuesFiles []string              `json:"valuesFiles,omitempty" jsonschema:"description=List of Helm chart value file  paths to set statically"`
}

BundleChartOverrides represents a Helm chart override to set via UDS variables

type BundleChartValue

type BundleChartValue struct {
	Path  string      `` /* 127-byte string literal not displayed */
	Value interface{} `json:"value" jsonschema:"name=The value to set"`
}

type BundleChartVariable

type BundleChartVariable struct {
	Path        string              `` /* 127-byte string literal not displayed */
	Name        string              `json:"name" jsonschema:"name=Name of the variable to set"`
	Description string              `json:"description,omitempty" jsonschema:"name=Description of the variable"`
	Default     interface{}         `json:"default,omitempty" jsonschema:"name=The default value to set"`
	Type        chartvariable.Type  `json:"type,omitempty" jsonschema:"description=The type of value to be processed,enum=raw,enum=file"`
	Sensitive   bool                `json:"sensitive,omitempty" jsonschema:"description=Whether the value is sensitive"`
	Source      valuesources.Source `json:"source,omitempty" jsonschema:"description=Where the value is set from,enum=config,enum=env,enum=cli,enum=bundle"`
}

type BundleCommonOptions

type BundleCommonOptions struct {
	Confirm        bool   `json:"confirm" jsonschema:"description=Verify that Zarf should perform an action"`
	Insecure       bool   `json:"insecure" jsonschema:"description=Allow insecure connections for remote packages"`
	CachePath      string `json:"cachePath" jsonschema:"description=Path to use to cache images and git repos on package create"`
	TempDirectory  string `` /* 157-byte string literal not displayed */
	OCIConcurrency int    `jsonschema:"description=Number of concurrent layer operations to perform when interacting with a remote package"`
}

BundleCommonOptions tracks the user-defined preferences used across commands.

type BundleConfig

type BundleConfig struct {
	CreateOpts    BundleCreateOptions
	DeployOpts    BundleDeployOptions
	PublishOpts   BundlePublishOptions
	PullOpts      BundlePullOptions
	InspectOpts   BundleInspectOptions
	RemoveOpts    BundleRemoveOptions
	DevDeployOpts BundleDevDeployOptions
}

BundleConfig is the main struct that the bundler uses to hold high-level options.

type BundleCreateOptions

type BundleCreateOptions struct {
	SourceDirectory    string
	Output             string
	SigningKeyPath     string
	SigningKeyPassword string
	BundleFile         string
	Version            string
	Name               string
}

BundleCreateOptions is the options for the bundler.Create() function

type BundleDeployOptions

type BundleDeployOptions struct {
	Resume        bool
	Source        string
	Config        string
	Packages      []string
	PublicKeyPath string
	SetVariables  map[string]string `` /* 154-byte string literal not displayed */
	// Variables and SharedVariables are read in from uds-config.yaml
	Variables       map[string]map[string]interface{} `yaml:"variables,omitempty"`
	SharedVariables map[string]interface{}            `yaml:"shared,omitempty"`
	Retries         int                               `yaml:"retries"`
	Options         map[string]interface{}            `yaml:"options,omitempty"`
}

BundleDeployOptions is the options for the bundler.Deploy() function

type BundleDevDeployOptions added in v0.11.1

type BundleDevDeployOptions struct {
	FlavorInput string
	Flavor      map[string]string
	ForceCreate bool
	Ref         map[string]string
}

BundleDevDeployOptions are the options for when doing a dev deploy

type BundleInspectOptions

type BundleInspectOptions struct {
	PublicKeyPath string
	Source        string
	IncludeSBOM   bool
	ExtractSBOM   bool
	ListImages    bool
	ListVariables bool
	IsYAMLFile    bool
}

BundleInspectOptions is the options for the bundler.Inspect() function

type BundlePublishOptions

type BundlePublishOptions struct {
	Source      string
	Destination string
	Version     string
}

BundlePublishOptions is the options for the bundle.Publish() function

type BundlePullOptions

type BundlePullOptions struct {
	OutputDirectory string
	PublicKeyPath   string
	Source          string
}

BundlePullOptions is the options for the bundler.Pull() function

type BundleRemoveOptions

type BundleRemoveOptions struct {
	Source   string
	Packages []string
}

BundleRemoveOptions is the options for the bundler.Remove() function

type BundleVariableExport

type BundleVariableExport struct {
	Name        string `json:"name" jsonschema:"name=Name of the variable"`
	Description string `json:"description,omitempty" jsonschema:"name=Description of the variable"`
}

BundleVariableExport represents variables in the bundle

type BundleVariableImport

type BundleVariableImport struct {
	Name        string `json:"name" jsonschema:"name=Name of the variable"`
	Package     string `json:"package" jsonschema:"name=Name of the Zarf package to get the variable from"`
	Description string `json:"description,omitempty" jsonschema:"name=Description of the variable"`
}

BundleVariableImport represents variables in the bundle

type Package

type Package struct {
	Name               string                                     `json:"name" jsonschema:"name=Name of the Zarf package"`
	Description        string                                     `json:"description,omitempty" jsonschema:"description=Description of the Zarf package"`
	Repository         string                                     `json:"repository,omitempty" jsonschema:"description=The repository to import the package from"`
	Path               string                                     `json:"path,omitempty" jsonschema:"description=The local path to import the package from"`
	Ref                string                                     `json:"ref" jsonschema:"description=Ref (tag) of the Zarf package"`
	Flavor             string                                     `json:"flavor,omitempty" jsonschema:"description=Flavor of the Zarf package"`
	OptionalComponents []string                                   `` /* 158-byte string literal not displayed */
	PublicKey          string                                     `json:"publicKey,omitempty" jsonschema:"description=The public key to use to verify the package"`
	Imports            []BundleVariableImport                     `json:"imports,omitempty" jsonschema:"description=List of Zarf variables to import from another Zarf package"`
	Exports            []BundleVariableExport                     `json:"exports,omitempty" jsonschema:"description=List of Zarf variables to export from the Zarf package"`
	Overrides          map[string]map[string]BundleChartOverrides `` /* 129-byte string literal not displayed */
}

Package represents a Zarf package in a UDS bundle

type PathMap

type PathMap map[string]string

PathMap is a map of either absolute paths to relative paths or relative paths to absolute paths used to map filenames during local bundle tarball creation

type UDSBuildData

type UDSBuildData struct {
	Terminal     string `json:"terminal" jsonschema:"description=The machine name that created this package"`
	User         string `json:"user" jsonschema:"description=The username who created this package"`
	Architecture string `json:"architecture" jsonschema:"description=The architecture this package was created on"`
	Timestamp    string `json:"timestamp" jsonschema:"description=The timestamp when this package was created"`
	Version      string `json:"version" jsonschema:"description=The version of Zarf used to build this package"`
}

UDSBuildData is written during the bundle.Create() operation to track details of the created package.

type UDSBundle

type UDSBundle struct {
	Kind     string       `json:"kind" jsonschema:"description=The kind of UDS package,enum=UDSBundle"`
	Metadata UDSMetadata  `json:"metadata" jsonschema:"description=UDSBundle metadata"`
	Build    UDSBuildData `json:"build,omitempty" jsonschema:"description=Generated bundle build data"`
	Packages []Package    `json:"packages" jsonschema:"description=List of Zarf packages"`
}

UDSBundle is the top-level structure of a UDS bundle

type UDSMetadata

type UDSMetadata struct {
	Name              string `json:"name" jsonschema:"description=Name to identify this UDS bundle,pattern=^[a-z0-9\\-]+$"`
	Description       string `json:"description,omitempty" jsonschema:"description=Additional information about this package"`
	Version           string `json:"version,omitempty" jsonschema:"description=Generic string set by a package author to track the package version"`
	URL               string `json:"url,omitempty" jsonschema:"description=Link to package information when online"`
	Uncompressed      bool   `json:"uncompressed,omitempty" jsonschema:"description=Disable compression of this package"`
	Architecture      string `` /* 131-byte string literal not displayed */
	Authors           string `` /* 209-byte string literal not displayed */
	Documentation     string `json:"documentation,omitempty" jsonschema:"description=Link to package documentation when online"`
	Source            string `json:"source,omitempty" jsonschema:"description=Link to package source code when online"`
	Vendor            string `json:"vendor,omitempty" jsonschema_description:"Name of the distributing entity, organization or individual."`
	AggregateChecksum string `` /* 151-byte string literal not displayed */
}

UDSMetadata lists information about the current UDS Bundle.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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