github.com/gocrane/crane@v0.11.0/examples/ensurance/evict-on-cpu-usage-total/be-rules.yaml (about) 1 apiVersion: ensurance.crane.io/v1alpha1 2 kind: PodQOS 3 metadata: 4 name: all-be-pods 5 spec: 6 allowedActions: 7 - eviction 8 scopeSelector: 9 matchExpressions: 10 - operator: In 11 scopeName: QOSClass 12 values: 13 - BestEffort 14 --- 15 apiVersion: ensurance.crane.io/v1alpha1 16 kind: NodeQOS 17 metadata: 18 name: eviction-on-high-usage 19 spec: 20 nodeQualityProbe: 21 nodeLocalGet: 22 localCacheTTLSeconds: 60 23 timeoutSeconds: 10 24 rules: 25 - actionName: eviction 26 avoidanceThreshold: 2 27 metricRule: 28 name: cpu_total_usage 29 value: 5000 30 name: cpu-usage 31 restoreThreshold: 2 32 strategy: None 33 --- 34 apiVersion: ensurance.crane.io/v1alpha1 35 kind: AvoidanceAction 36 metadata: 37 name: eviction 38 spec: 39 coolDownSeconds: 300 40 description: evict low priority pods 41 eviction: 42 terminationGracePeriodSeconds: 30