Commit c1f5551
reduce infra container's selinux privilege
before, if a pod was privileged, a pause container was set as privileged. This caused the rest of the containers in the pod to also need to inherit privileged labels from the pod (so they can join the pause container's namespaces).
In reality, there's little need for the pause container to have privileged (spc_t) label. It can manage an unprivileged namespace, and containers can join regardless of privilege. Further, the privilege of the pause container doesn't affect its ability to reap (if the pod shares pid).
Unconditionally set the pause container's process label, so the rest of the (unprivileged) containers in the pod inherit it.
Signed-off-by: Peter Hunt <[email protected]>1 parent 5592167 commit c1f5551
1 file changed
+2
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
99 | 99 | | |
100 | 100 | | |
101 | 101 | | |
102 | | - | |
103 | | - | |
104 | | - | |
| 102 | + | |
| 103 | + | |
105 | 104 | | |
106 | 105 | | |
107 | 106 | | |
| |||
0 commit comments