Skip to content

Commit 31e4a0a

Browse files
JesseStutlerMonokaix
authored andcommitted
Fix the labelSelector capitalization issue and set memberSelector to one of three options
Signed-off-by: JesseStutler <[email protected]>
1 parent 9e72c73 commit 31e4a0a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pkg/apis/topology/v1alpha1/hypernode_types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,8 +95,8 @@ type MemberSpec struct {
9595
// regexMatch:
9696
// pattern: "^node-[0-9]+$"
9797
//
98-
// +kubebuilder:validation:XValidation:rule="has(self.exactMatch) || has(self.regexMatch) || has(self.LabelMatch)",message="Either ExactMatch or RegexMatch or LabelMatch must be specified"
99-
// +kubebuilder:validation:XValidation:rule="!(has(self.exactMatch) && has(self.regexMatch) && has(self.LabelMatch))",message="ExactMatch and RegexMatch and LabelMatch cannot be specified together"
98+
// +kubebuilder:validation:XValidation:rule="has(self.exactMatch) || has(self.regexMatch) || has(self.labelMatch)",message="Either ExactMatch or RegexMatch or LabelMatch must be specified"
99+
// +kubebuilder:validation:XValidation:rule="(has(self.exactMatch) ? 1 : 0) + (has(self.regexMatch) ? 1 : 0) + (has(self.labelMatch) ? 1 : 0) <= 1",message="Only one of ExactMatch, RegexMatch, or LabelMatch can be specified"
100100
type MemberSelector struct {
101101
// ExactMatch defines the exact match criteria.
102102
// +optional

0 commit comments

Comments
 (0)