bundle

package
v1.99.4 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2022 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CalculateBundleSha256Sum added in v1.99.2

func CalculateBundleSha256Sum(bundlePath string) (string, error)

func Download added in v1.99.2

func Download(preset preset.Preset) error

func GetBundleNameWithoutExtension added in v1.26.0

func GetBundleNameWithoutExtension(bundleName string) string

func GetCustomBundleName added in v1.26.0

func GetCustomBundleName(bundleFilename string) string

Types

type BuildInfo added in v1.20.0

type BuildInfo struct {
	BuildTime                 string `json:"buildTime"`
	OpenshiftInstallerVersion string `json:"openshiftInstallerVersion"`
	SncVersion                string `json:"sncVersion"`
}

type ClusterInfo added in v1.20.0

type ClusterInfo struct {
	OpenShiftVersion    *semver.Version `json:"openshiftVersion"`
	ClusterName         string          `json:"clusterName"`
	BaseDomain          string          `json:"baseDomain"`
	AppsDomain          string          `json:"appsDomain"`
	SSHPrivateKeyFile   string          `json:"sshPrivateKeyFile"`
	KubeConfig          string          `json:"kubeConfig"`
	OpenshiftPullSecret string          `json:"openshiftPullSecret,omitempty"`
}

type Copier added in v1.26.0

type Copier struct {
	// contains filtered or unexported fields
}

func NewCopier added in v1.26.0

func NewCopier(srcBundle *CrcBundleInfo, basePath string, customBundleName string) (*Copier, error)

func (*Copier) CachedPath added in v1.26.0

func (copier *Copier) CachedPath() string

func (*Copier) Cleanup added in v1.26.0

func (copier *Copier) Cleanup() error

func (*Copier) CopyFilesFromFileList added in v1.26.0

func (copier *Copier) CopyFilesFromFileList() error

func (*Copier) CopyKubeConfig added in v1.26.0

func (copier *Copier) CopyKubeConfig() error

func (*Copier) CopyPrivateSSHKey added in v1.26.0

func (copier *Copier) CopyPrivateSSHKey(srcPath string) error

func (*Copier) GenerateBundle added in v1.26.0

func (copier *Copier) GenerateBundle(bundleName string) error

func (*Copier) SetDiskImage added in v1.26.0

func (copier *Copier) SetDiskImage(path string, format string) error

type CrcBundleInfo

type CrcBundleInfo struct {
	Version     string      `json:"version"`
	Type        string      `json:"type"`
	Name        string      `json:"name"`
	BuildInfo   BuildInfo   `json:"buildInfo"`
	ClusterInfo ClusterInfo `json:"clusterInfo"`
	Nodes       []Node      `json:"nodes"`
	Storage     Storage     `json:"storage"`
	DriverInfo  DriverInfo  `json:"driverInfo"`
	// contains filtered or unexported fields
}

func Extract

func Extract(path string) (*CrcBundleInfo, error)

func Get added in v1.24.0

func Get(bundleName string) (*CrcBundleInfo, error)

func List added in v1.28.0

func List() ([]CrcBundleInfo, error)

func Use added in v1.24.0

func Use(bundleName string) (*CrcBundleInfo, error)

func (*CrcBundleInfo) GetAPIHostname

func (bundle *CrcBundleInfo) GetAPIHostname() string

func (*CrcBundleInfo) GetAppHostname

func (bundle *CrcBundleInfo) GetAppHostname(appName string) string

func (*CrcBundleInfo) GetBundleBuildTime

func (bundle *CrcBundleInfo) GetBundleBuildTime() (time.Time, error)

func (*CrcBundleInfo) GetBundleName added in v1.24.0

func (bundle *CrcBundleInfo) GetBundleName() string

func (*CrcBundleInfo) GetBundleNameWithoutExtension added in v1.26.0

func (bundle *CrcBundleInfo) GetBundleNameWithoutExtension() string

func (*CrcBundleInfo) GetBundleType added in v1.99.2

func (bundle *CrcBundleInfo) GetBundleType() preset.Preset

func (*CrcBundleInfo) GetDiskImageFormat added in v1.26.0

func (bundle *CrcBundleInfo) GetDiskImageFormat() string

func (*CrcBundleInfo) GetDiskImagePath

func (bundle *CrcBundleInfo) GetDiskImagePath() string

func (*CrcBundleInfo) GetInitramfsPath

func (bundle *CrcBundleInfo) GetInitramfsPath() string

func (*CrcBundleInfo) GetKernelCommandLine added in v1.26.0

func (bundle *CrcBundleInfo) GetKernelCommandLine() string

func (*CrcBundleInfo) GetKernelPath

func (bundle *CrcBundleInfo) GetKernelPath() string

func (*CrcBundleInfo) GetKubeConfigPath

func (bundle *CrcBundleInfo) GetKubeConfigPath() string

func (*CrcBundleInfo) GetOcPath added in v1.25.0

func (bundle *CrcBundleInfo) GetOcPath() string

func (*CrcBundleInfo) GetOpenshiftVersion

func (bundle *CrcBundleInfo) GetOpenshiftVersion() string

func (*CrcBundleInfo) GetPodmanPath added in v1.26.0

func (bundle *CrcBundleInfo) GetPodmanPath() string

func (*CrcBundleInfo) GetPodmanVersion added in v1.99.2

func (bundle *CrcBundleInfo) GetPodmanVersion() string

func (*CrcBundleInfo) GetSSHKeyPath

func (bundle *CrcBundleInfo) GetSSHKeyPath() string

func (*CrcBundleInfo) IsOpenShift added in v1.99.2

func (bundle *CrcBundleInfo) IsOpenShift() bool

type DiskImage added in v1.20.0

type DiskImage struct {
	File
	Format string `json:"format"`
}

type DriverInfo added in v1.20.0

type DriverInfo struct {
	Name string `json:"name"`
}

type File added in v1.25.0

type File struct {
	Name     string `json:"name"`
	Size     string `json:"size"`
	Checksum string `json:"sha256sum"`
}

type FileListItem added in v1.25.0

type FileListItem struct {
	File
	Type FileType `json:"type"`
}

type FileType added in v1.26.0

type FileType string
const (
	OcExecutable     FileType = "oc-executable"
	PodmanExecutable FileType = "podman-executable"
)

type Node added in v1.20.0

type Node struct {
	Kind          []string `json:"kind"`
	Hostname      string   `json:"hostname"`
	DiskImage     string   `json:"diskImage"`
	KernelCmdLine string   `json:"kernelCmdLine,omitempty"`
	Initramfs     string   `json:"initramfs,omitempty"`
	Kernel        string   `json:"kernel,omitempty"`
	InternalIP    string   `json:"internalIP"`
	PodmanVersion string   `json:"podmanVersion,omitempty"`
}

type Repository added in v1.20.0

type Repository struct {
	CacheDir string
	OcBinDir string
}

func (*Repository) CalculateBundleSha256Sum added in v1.99.2

func (repo *Repository) CalculateBundleSha256Sum(bundlePath string) (string, error)

func (*Repository) Extract added in v1.20.0

func (repo *Repository) Extract(path string) error

func (*Repository) Get added in v1.20.0

func (repo *Repository) Get(bundleName string) (*CrcBundleInfo, error)

func (*Repository) List added in v1.28.0

func (repo *Repository) List() ([]CrcBundleInfo, error)

func (*Repository) Use added in v1.20.0

func (repo *Repository) Use(bundleName string) (*CrcBundleInfo, error)

type Storage added in v1.20.0

type Storage struct {
	DiskImages []DiskImage    `json:"diskImages"`
	Files      []FileListItem `json:"fileList"`
}

Jump to

Keyboard shortcuts

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