@@ -51,23 +51,26 @@ type VMDistributedClusterSpec struct {
5151// VMClusterRefOrSpec is either a reference to existing VMCluster or a specification of a new VMCluster.
5252// +kubebuilder:validation:Xor=Ref,Spec
5353type VMClusterRefOrSpec struct {
54- // Name specifies the static name to be used for the VMCluster when Spec is provided.
55- // If Ref is used, this field is ignored.
56- // +optional
57- Name string `json:"name,omitempty"`
5854 // Ref points to the VMCluster object.
55+ // If Ref is specified, Name and Spec are ignored.
5956 // +optional
6057 Ref * corev1.LocalObjectReference `json:"ref,omitempty"`
61- // Spec defines the desired state of a new VMCluster.
62- // +optional
63- Spec * vmv1beta1.VMClusterSpec `json:"spec,omitempty"`
6458 // OverrideSpec specifies an override to the VMClusterSpec of the referenced object.
65- // This field is ignored if `Spec` is specified.
6659 // This override is applied to the referenced object if `Ref` is specified.
60+ // This field is ignored if `Spec` is specified.
6761 // +kubebuilder:validation:Type=object
6862 // +kubebuilder:validation:XPreserveUnknownFields
6963 // +optional
7064 OverrideSpec * apiextensionsv1.JSON `json:"overrideSpec,omitempty"`
65+
66+ // Name specifies the static name to be used for the VMCluster when Spec is provided.
67+ // This field is ignored if `Ref` is specified.
68+ // +optional
69+ Name string `json:"name,omitempty"`
70+ // Spec defines the desired state of a new VMCluster.
71+ // This field is ignored if `Ref` is specified.
72+ // +optional
73+ Spec * vmv1beta1.VMClusterSpec `json:"spec,omitempty"`
7174}
7275
7376// +k8s:openapi-gen=true
0 commit comments