utils

package
v1.59.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	// CDILabel is the labe applied to all non operator resources
	CDILabel = "cdi.kubevirt.io"
	// CDIPriorityClass is the priority class for all CDI pods.
	CDIPriorityClass = "kubevirt-cluster-critical"
)

Variables

View Source
var ResourceBuilder = utils.NewResourceBuilder(commonLabels, operatorLabels)

ResourceBuilder helps in creating k8s resources

Functions

func AddPodPreferredDuringSchedulingIgnoredDuringExecution added in v1.59.0

func AddPodPreferredDuringSchedulingIgnoredDuringExecution(name string, affinity *corev1.Affinity) *corev1.Affinity

AddPodPreferredDuringSchedulingIgnoredDuringExecution to affinity

func CreateContainer

func CreateContainer(name, image, verbosity, pullPolicy string) corev1.Container

CreateContainer creates container

func CreateDeployment

func CreateDeployment(name, matchKey, matchValue, serviceAccountName string, imagePullSecrets []corev1.LocalObjectReference, replicas int32, infraNodePlacement *sdkapi.NodePlacement) *appsv1.Deployment

CreateDeployment creates deployment

func CreateOperatorDeployment

func CreateOperatorDeployment(name, namespace, matchKey, matchValue, serviceAccount string, imagePullSecrets []corev1.LocalObjectReference, numReplicas int32) *appsv1.Deployment

CreateOperatorDeployment creates operator deployment

func CreatePortsContainer

func CreatePortsContainer(name, image, pullPolicy string, ports []corev1.ContainerPort) corev1.Container

CreatePortsContainer creates container with ports

Types

This section is empty.

Jump to

Keyboard shortcuts

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