testobjects

package
v0.0.0-...-7a8ee34 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2024 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTestSecret

func NewTestSecret(stringData map[string]string) *corev1.Secret

func NewTestVMI

func NewTestVMI() *v1.VirtualMachineInstance

Types

type CloudConfig

type CloudConfig struct {
	Password string `json:"password"`
	Chpasswd struct {
		Expire bool `json:"expire"`
	} `json:"chpasswd"`
	SSHAuthorizedKeys []string           `json:"ssh_authorized_keys"`
	SSHKeys           CloudConfigSSHKeys `json:"ssh_keys"`
}

func (CloudConfig) ToString

func (c CloudConfig) ToString() string

type CloudConfigSSHKeys

type CloudConfigSSHKeys struct {
	RSAPrivate string `json:"rsa_private"`
	RSAPublic  string `json:"rsa_public"`
}

type TestVM

type TestVM struct {
	Data *v1.VirtualMachine
}

func NewTestAlpineVM

func NewTestAlpineVM(name string) *TestVM

func NewTestFedoraCloudVM

func NewTestFedoraCloudVM(name string) *TestVM

func NewTestVM

func NewTestVM() *TestVM

func (*TestVM) Build

func (t *TestVM) Build() *v1.VirtualMachine

func (*TestVM) ToString

func (t *TestVM) ToString() string

func (*TestVM) WithCloudConfig

func (t *TestVM) WithCloudConfig(cloudConfig CloudConfig) *TestVM

func (*TestVM) WithDisk

func (t *TestVM) WithDisk(disk v1.Disk) *TestVM

func (*TestVM) WithLabel

func (t *TestVM) WithLabel(key, value string) *TestVM

func (*TestVM) WithMemory

func (t *TestVM) WithMemory(memory string) *TestVM

func (*TestVM) WithNonMatchingDisk

func (t *TestVM) WithNonMatchingDisk() *TestVM

func (*TestVM) WithVMILabel

func (t *TestVM) WithVMILabel(key, value string) *TestVM

func (*TestVM) WithVolume

func (t *TestVM) WithVolume(volume v1.Volume) *TestVM

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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