Documentation ¶
Overview ¶
Package check implements checks for managed topology.
Index ¶
- func ClusterClassReferencesAreValid(clusterClass *clusterv1.ClusterClass) field.ErrorList
- func ClusterClassesAreCompatible(current, desired *clusterv1.ClusterClass) field.ErrorList
- func LocalObjectTemplateIsValid(template *clusterv1.LocalObjectTemplate, namespace string, ...) field.ErrorList
- func LocalObjectTemplatesAreCompatible(current, desired clusterv1.LocalObjectTemplate, pathPrefix *field.Path) field.ErrorList
- func LocalObjectTemplatesAreInSameNamespace(current, desired clusterv1.LocalObjectTemplate, pathPrefix *field.Path) field.ErrorList
- func MachineDeploymentClassesAreCompatible(current, desired *clusterv1.ClusterClass) field.ErrorList
- func MachineDeploymentClassesAreUnique(clusterClass *clusterv1.ClusterClass) field.ErrorList
- func MachineDeploymentTopologiesAreValidAndDefinedInClusterClass(desired *clusterv1.Cluster, clusterClass *clusterv1.ClusterClass) field.ErrorList
- func ObjectsAreCompatible(current, desired client.Object) field.ErrorList
- func ObjectsAreInTheSameNamespace(current, desired client.Object) field.ErrorList
- func ObjectsAreStrictlyCompatible(current, desired client.Object) field.ErrorList
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClusterClassReferencesAreValid ¶
func ClusterClassReferencesAreValid(clusterClass *clusterv1.ClusterClass) field.ErrorList
ClusterClassReferencesAreValid checks that each template reference in the ClusterClass is valid .
func ClusterClassesAreCompatible ¶
func ClusterClassesAreCompatible(current, desired *clusterv1.ClusterClass) field.ErrorList
ClusterClassesAreCompatible checks the compatibility between new and old versions of a Cluster Class. It checks that: 1) InfrastructureCluster Templates are compatible. 2) ControlPlane Templates are compatible. 3) ControlPlane InfrastructureMachineTemplates are compatible. 4) MachineDeploymentClasses have not been deleted and are compatible.
func LocalObjectTemplateIsValid ¶
func LocalObjectTemplateIsValid(template *clusterv1.LocalObjectTemplate, namespace string, pathPrefix *field.Path) field.ErrorList
LocalObjectTemplateIsValid ensures the template is in the correct namespace, has no nil references, and has a valid Kind and GroupVersion.
func LocalObjectTemplatesAreCompatible ¶
func LocalObjectTemplatesAreCompatible(current, desired clusterv1.LocalObjectTemplate, pathPrefix *field.Path) field.ErrorList
LocalObjectTemplatesAreCompatible checks if two referenced objects are compatible, meaning that they are of the same GroupKind and in the same namespace.
func LocalObjectTemplatesAreInSameNamespace ¶
func LocalObjectTemplatesAreInSameNamespace(current, desired clusterv1.LocalObjectTemplate, pathPrefix *field.Path) field.ErrorList
LocalObjectTemplatesAreInSameNamespace checks if two referenced objects are in the same namespace.
func MachineDeploymentClassesAreCompatible ¶
func MachineDeploymentClassesAreCompatible(current, desired *clusterv1.ClusterClass) field.ErrorList
MachineDeploymentClassesAreCompatible checks if each MachineDeploymentClass in the new ClusterClass is a compatible change from the previous ClusterClass. It checks if: 1) Any MachineDeploymentClass has been removed. 2) If the MachineDeploymentClass.Template.Infrastructure reference has changed its Group or Kind.
func MachineDeploymentClassesAreUnique ¶
func MachineDeploymentClassesAreUnique(clusterClass *clusterv1.ClusterClass) field.ErrorList
MachineDeploymentClassesAreUnique checks that no two MachineDeploymentClasses in a ClusterClass share a name.
func MachineDeploymentTopologiesAreValidAndDefinedInClusterClass ¶
func MachineDeploymentTopologiesAreValidAndDefinedInClusterClass(desired *clusterv1.Cluster, clusterClass *clusterv1.ClusterClass) field.ErrorList
MachineDeploymentTopologiesAreValidAndDefinedInClusterClass checks that each MachineDeploymentTopology name is not empty and unique, and each class in use is defined in ClusterClass.spec.Workers.MachineDeployments.
func ObjectsAreCompatible ¶
ObjectsAreCompatible checks if two referenced objects are compatible, meaning that they are of the same GroupKind and in the same namespace.
func ObjectsAreInTheSameNamespace ¶
ObjectsAreInTheSameNamespace checks if two referenced objects are in the same namespace.
Types ¶
This section is empty.