Skip to content

Commit 05570d4

Browse files
authored
Merge pull request kubernetes#2483 from ahg-g/ahg-fit-strategy
Remove the restriction on empty namespaceSelector in podaffinity
2 parents fd57a85 + b0462c4 commit 05570d4

File tree

1 file changed

+2
-23
lines changed
  • keps/sig-scheduling/2249-pod-affinity-namespace-selector

1 file changed

+2
-23
lines changed

keps/sig-scheduling/2249-pod-affinity-namespace-selector/README.md

Lines changed: 2 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -316,28 +316,6 @@ if the namespace where they are created have a resource quota object with
316316
`CrossNamespaceAffinity` scope and a hard limit equal to the number of pods that are
317317
allowed to.
318318

319-
Moreover, to prevent accidentally selecting a large number of namespaces, we will reject empty
320-
selectors. For example, users can do the following:
321-
322-
```yaml
323-
podAntiAffinity:
324-
requiredDuringSchedulingIgnoredDuringExecution:
325-
- namespaceSelector:
326-
matchExpressions:
327-
- key: workload
328-
operator: In
329-
values:
330-
- HPC
331-
```
332-
333-
but can't do the following:
334-
335-
```yaml
336-
podAntiAffinity:
337-
requiredDuringSchedulingIgnoredDuringExecution:
338-
- namespaceSelector: {}
339-
```
340-
341319
For more protection, admission webhooks like gatekeeper can be used to further
342320
restrict the use of this field.
343321

@@ -700,7 +678,8 @@ information to express the idea and why it was not acceptable.
700678

701679
## Implementation History
702680
- 2021-01-11: Initial KEP sent for review
703-
681+
- 2021-02-10: Remove the restriction on empty namespace selector
682+
704683
<!--
705684
Major milestones in the lifecycle of a KEP should be tracked in this section.
706685
Major milestones might include:

0 commit comments

Comments
 (0)