controllerutils

package
v0.1.9 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2025 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanAMDGPUName added in v0.1.6

func CleanAMDGPUName(gpuID string) string

func CompareClusterQueues

func CompareClusterQueues(a, b kueuev1beta1.ClusterQueue) bool

func ComparePriorityClasses

func ComparePriorityClasses(a, b kueuev1beta1.WorkloadPriorityClass) bool

func CompareResourceFlavors

func CompareResourceFlavors(a, b kueuev1beta1.ResourceFlavor) bool

func CompareTopologies added in v0.1.6

func CompareTopologies(a, b kueuev1alpha1.Topology) bool

func ConvertKaiwoToKueueClusterQueue

func ConvertKaiwoToKueueClusterQueue(kaiwoQueue kaiwo.ClusterQueue) kueuev1beta1.ClusterQueue

func ConvertKaiwoToKueueResourceFlavor

func ConvertKaiwoToKueueResourceFlavor(kaiwoFlavor kaiwo.ResourceFlavorSpec) kueuev1beta1.ResourceFlavor

func ConvertKaiwoToKueueResourceFlavors

func ConvertKaiwoToKueueResourceFlavors(kaiwoFlavors []kaiwo.ResourceFlavorSpec) []kueuev1beta1.ResourceFlavor

func ConvertKaiwoToKueueSpec added in v0.1.6

func ConvertKaiwoToKueueSpec(in kaiwo.ClusterQueueSpec) kueuev1beta1.ClusterQueueSpec

ConvertKaiwoToKueueSpec converts from Kaiwo's simplified ClusterQueueSpec to the actual Kueue version

func ConvertKaiwoToKueueTopologies added in v0.1.6

func ConvertKaiwoToKueueTopologies(kaiwoTopologies []kaiwo.Topology) []kueuev1alpha1.Topology

func ConvertKaiwoToKueueTopology added in v0.1.6

func ConvertKaiwoToKueueTopology(kaiwoTopology kaiwo.Topology) kueuev1alpha1.Topology

func CreateClusterQueue

func CreateClusterQueue(nodePoolResources map[string]kueuev1beta1.FlavorQuotas, name string, cohort string) kaiwo.ClusterQueue

func CreateDefaultTopology added in v0.1.6

func CreateDefaultTopology(ctx context.Context, c client.Client) ([]kaiwo.Topology, error)

func CreateLocalQueue

func CreateLocalQueue(ctx context.Context, c client.Client, name string, namespace string) error

CreateLocalQueue creates a LocalQueue in the given namespace.

func EnsureNamespaceKueueManaged

func EnsureNamespaceKueueManaged(ctx context.Context, k8sClient client.Client, namespaceName string) error

func FindFlavor

func FindFlavor(flavors []kueuev1beta1.ResourceFlavor, name string) (kueuev1beta1.ResourceFlavor, bool)

func FindTopology added in v0.1.6

func FindTopology(topologies []kueuev1alpha1.Topology, name string) (kueuev1alpha1.Topology, bool)

func LabelNode

func LabelNode(ctx context.Context, c client.Client, nodeName, key, value string) error

func RemoveDuplicateResourceFlavors

func RemoveDuplicateResourceFlavors(flavors []kaiwo.ResourceFlavorSpec) []kaiwo.ResourceFlavorSpec

func TaintNode

func TaintNode(ctx context.Context, client client.Client, nodeName string, taint corev1.Taint) error

Types

type NodeResourceInfo

type NodeResourceInfo struct {
	Name          string
	CPU           int
	Memory        int
	Labels        map[string]string
	Unschedulable bool
}

func GetNodeResources

func GetNodeResources(ctx context.Context, c client.Client) []NodeResourceInfo

Jump to

Keyboard shortcuts

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