mirror of
https://github.com/kubernetes-sigs/descheduler.git
synced 2026-01-26 13:29:11 +01:00
Migrate RemovePodsViolatingInterPodAntiAffinity into a plugin
This commit is contained in:
@@ -94,6 +94,14 @@ func ValidateRemovePodsViolatingTopologySpreadConstraintArgs(args *componentconf
|
||||
)
|
||||
}
|
||||
|
||||
// ValidateRemovePodsViolatingInterPodAntiAffinityArgs validates ValidateRemovePodsViolatingInterPodAntiAffinity arguments
|
||||
func ValidateRemovePodsViolatingInterPodAntiAffinityArgs(args *componentconfig.RemovePodsViolatingInterPodAntiAffinityArgs) error {
|
||||
return errorsAggregate(
|
||||
validateNamespaceArgs(args.Namespaces),
|
||||
validateLabelSelectorArgs(args.LabelSelector),
|
||||
)
|
||||
}
|
||||
|
||||
// errorsAggregate converts all arg validation errors to a single error interface.
|
||||
// if no errors, it will return nil.
|
||||
func errorsAggregate(errors ...error) error {
|
||||
|
||||
Reference in New Issue
Block a user