vmi

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: May 1, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// CRIOCPULoadBalancingAnnotation indicates that load balancing should be disabled for CPUs used by the container
	CRIOCPULoadBalancingAnnotation = "cpu-load-balancing.crio.io"

	// CRIOCPUQuotaAnnotation indicates that CPU quota should be disabled for CPUs used by the container
	CRIOCPUQuotaAnnotation = "cpu-quota.crio.io"

	// CRIOIRQLoadBalancingAnnotation indicates that IRQ load balancing should be disabled for CPUs used by the container
	CRIOIRQLoadBalancingAnnotation = "irq-load-balancing.crio.io"
)
View Source
const Disable = "disable"

Variables

This section is empty.

Functions

func New

func New(name string, options ...Option) *kvcorev1.VirtualMachineInstance

func NewPreferredPodAntiAffinity added in v0.2.0

func NewPreferredPodAntiAffinity(labelKey, labelVal string) *k8scorev1.PodAntiAffinity

NewPreferredPodAntiAffinity returns new pod anti-affinity with label selector of the given label key and value. Adding it to a VMI will make sure it won't schedule on the same node as other VMIs with the given label.

func NewRequiredNodeAffinity added in v0.2.0

func NewRequiredNodeAffinity(nodeName string) *k8scorev1.NodeAffinity

NewRequiredNodeAffinity returns new node affinity with node selector of the given node name. Adding it to a VMI will make sure it will schedule on the given node name.

func Pointer

func Pointer[T any](v T) *T

Types

type Option

type Option func(vmi *kvcorev1.VirtualMachineInstance)

func WithAffinity added in v0.2.0

func WithAffinity(affinity *corev1.Affinity) Option

WithAffinity adds the given affinity.

func WithCloudInitNoCloudVolume

func WithCloudInitNoCloudVolume(name, userData string) Option

func WithConfigMapDisk added in v0.2.0

func WithConfigMapDisk(name, serial string) Option

func WithConfigMapVolume added in v0.2.0

func WithConfigMapVolume(name, configMapName string) Option

func WithContainerDisk

func WithContainerDisk(volumeName, imageName string) Option

func WithDedicatedCPU

func WithDedicatedCPU(socketsCount, coresCount, threadsCount uint32) Option

func WithLabels added in v0.2.0

func WithLabels(labels map[string]string) Option

WithLabels adds the given labels.

func WithMemory added in v0.2.0

func WithMemory(hugePageSize, guestMemory string) Option

func WithMultusNetwork

func WithMultusNetwork(name, networkAttachmentDefinitionName string) Option

func WithNetworkInterfaceMultiQueue

func WithNetworkInterfaceMultiQueue() Option

func WithOwnerReference

func WithOwnerReference(ownerName, ownerUID string) Option

func WithRandomNumberGenerator

func WithRandomNumberGenerator() Option

func WithReadinessFileProbe added in v0.3.1

func WithReadinessFileProbe(fileName string) Option

func WithSRIOVInterface

func WithSRIOVInterface(name, macAddress, pciAddress string) Option

func WithTerminationGracePeriodSeconds

func WithTerminationGracePeriodSeconds(terminationGracePeriodSeconds int64) Option

func WithVirtIODisk

func WithVirtIODisk(name string) Option

func WithoutCRIOCPULoadBalancing

func WithoutCRIOCPULoadBalancing() Option

func WithoutCRIOCPUQuota

func WithoutCRIOCPUQuota() Option

func WithoutCRIOIRQLoadBalancing

func WithoutCRIOIRQLoadBalancing() Option

Jump to

Keyboard shortcuts

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