mirror of
https://github.com/kubernetes-sigs/descheduler.git
synced 2026-01-27 05:46:13 +01:00
add namespace filter to nodeutilization
This commit is contained in:
@@ -19,7 +19,16 @@ import (
|
||||
)
|
||||
|
||||
func ValidateHighNodeUtilizationArgs(args *HighNodeUtilizationArgs) error {
|
||||
return validateThresholds(args.Thresholds)
|
||||
// only exclude can be set, or not at all
|
||||
if args.EvictableNamespaces != nil && len(args.EvictableNamespaces.Include) > 0 {
|
||||
return fmt.Errorf("only Exclude namespaces can be set, inclusion is not supported")
|
||||
}
|
||||
err := validateThresholds(args.Thresholds)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func ValidateLowNodeUtilizationArgs(args *LowNodeUtilizationArgs) error {
|
||||
|
||||
Reference in New Issue
Block a user