machine

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// FakeVersion is the version of the fake runtime.
	FakeVersion = "0.1.0"

	// FakeRuntimeName is the name of the fake runtime.
	FakeRuntimeName = "fakeRuntime"
)

Functions

This section is empty.

Types

type FakeMachine

type FakeMachine struct {
	ori.Machine
}

type FakeMachineClass

type FakeMachineClass struct {
	ori.MachineClass
}

type FakeNetworkInterface

type FakeNetworkInterface struct {
	ori.NetworkInterface
}

type FakeRuntimeService

type FakeRuntimeService struct {
	sync.Mutex

	Machines          map[string]*FakeMachine
	Volumes           map[string]*FakeVolume
	NetworkInterfaces map[string]*FakeNetworkInterface
	MachineClasses    map[string]*FakeMachineClass
	GetExecURL        func(req *ori.ExecRequest) string
}

func NewFakeRuntimeService

func NewFakeRuntimeService() *FakeRuntimeService

func (*FakeRuntimeService) CreateMachine

func (*FakeRuntimeService) CreateNetworkInterface

func (*FakeRuntimeService) CreateVolume

func (*FakeRuntimeService) CreateVolumeAttachment

func (*FakeRuntimeService) DeleteMachine

func (*FakeRuntimeService) DeleteNetworkInterface

func (*FakeRuntimeService) DeleteVolume

func (*FakeRuntimeService) DeleteVolumeAttachment

func (*FakeRuntimeService) Exec

func (*FakeRuntimeService) ListMachineClasses

func (*FakeRuntimeService) ListMachines

func (*FakeRuntimeService) ListNetworkInterfaces

func (*FakeRuntimeService) ListVolumes

func (*FakeRuntimeService) SetGetExecURL

func (r *FakeRuntimeService) SetGetExecURL(f func(req *ori.ExecRequest) string)

func (*FakeRuntimeService) SetMachineClasses

func (r *FakeRuntimeService) SetMachineClasses(machineClasses []*FakeMachineClass)

func (*FakeRuntimeService) SetMachines

func (r *FakeRuntimeService) SetMachines(machines []*FakeMachine)

func (*FakeRuntimeService) SetNetworkInterfaces

func (r *FakeRuntimeService) SetNetworkInterfaces(networkInterfaces []*FakeNetworkInterface)

func (*FakeRuntimeService) SetVolumes

func (r *FakeRuntimeService) SetVolumes(volumes []*FakeVolume)

func (*FakeRuntimeService) UpdateMachineAnnotations

func (*FakeRuntimeService) UpdateMachinePower

func (*FakeRuntimeService) Version

type FakeVolume

type FakeVolume struct {
	ori.Volume
}

Jump to

Keyboard shortcuts

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