virtualmachine

package
v1.1.0-rc2 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2022 License: Apache-2.0 Imports: 23 Imported by: 2

Documentation

Index

Constants

View Source
const (
	VirtualMachineCreatorNodeDriver = "docker-machine-driver-harvester"
)

Variables

This section is empty.

Functions

func Register

func Register(ctx context.Context, management *config.Management, options config.Options) error

Types

type VMController

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

func (*VMController) OnVMRemove added in v1.1.0

OnVMRemove handle related PVC and delete related VMBackup snapshot

func (*VMController) SetOwnerOfPVCs added in v0.3.0

SetOwnerOfPVCs records the target VirtualMachine as the owner of the PVCs in annotation.

func (*VMController) StoreRunStrategy added in v1.0.2

StoreRunStrategy stores the last running strategy into the annotation before the VM is stopped. As a workaround for the issue https://github.com/kubevirt/kubevirt/issues/7295

func (*VMController) SyncLabelsToVmi added in v1.1.0

SyncLabelsToVmi synchronizes the labels in the VM spec to the existing VMI without re-deployment

type VMIController

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

func (*VMIController) ReconcileFromHostLabels added in v1.0.3

ReconcileFromHostLabels handles the propagation of metadata from node labels to VirtualMachineInstance annotations.

func (*VMIController) UnsetOwnerOfPVCs added in v0.3.0

UnsetOwnerOfPVCs erases the target VirtualMachine from the owner of the PVCs in annotation.

When modifying the VirtualMachine's spec to remove the previously defined PVCs and recreating the VirtualMachineInstance, those previously defined PVCs still hold an OwnerReference of the VirtualMachine, but they are no longer used by the newly created VirtualMachineInstance.

Since the handler of VMController has recorded the relationship in the PVC's annotation, this handler will erase the target owner from the PVC's annotation to avoid logic leak.

type VMNetworkController

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

func (*VMNetworkController) SetDefaultNetworkMacAddress

SetDefaultNetworkMacAddress set the default mac address of networks using the initial allocated mac address from the VMI status, since the most guest OS will use the initial allocated mac address of its DHCP config, and on Kubevirt the VM restart it will re-allocate a new mac address which will lead the original network unreachable.

Jump to

Keyboard shortcuts

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