Watch
0
0
Fork
You've already forked hyperhive
0

k8s: stt's pod runs in a user namespace of its own

This commit is contained in:
atlas 2026-11-23 13:44:57 +01:00 • committed by maia
commit 7a45c7f1b4

View file

@ -101,6 +101,11 @@ credential directory.
escalation, every capability dropped, the runtime's default seccomp profile,
and no mounted API token. A service that logs in to the store gets a token
of its own, [below](#the-store-login).
`swarm-stt` also runs in a user namespace of its own (`hostUsers: false`), as
the unit's `PrivateUsers` does: its root and every id it holds are
unprivileged ids on the node. A volume keeps the in-pod ownership it has
without one, so `fsGroup` and the credential files' mode work as before.
A service asking for it needs a kernel of 6.3 or later (an assertion).
- **Resources:** the unit's `MemoryMax` becomes the container's memory limit
(systemd's `K`, `M`, `G` and `T` are Kubernetes' `Ki`, `Mi`, `Gi` and `Ti`; a
byte count passes unchanged; `infinity` sets none) and its `CPUQuota`, a
@ -110,9 +115,9 @@ credential directory.
cap on the node. The memory request is the unit's `MemoryMin`, else its
`MemoryLow`, else `0`, and the cpu request is `0`, so the pod is Burstable. A
value in another form fails evaluation. `TasksMax` has no pod field, so the
renderer drops it. The unit's sandbox settings
(`MemoryDenyWriteExecute`, `SystemCallFilter`, `PrivateUsers` and the rest)
stay on the host: the pod has the security shape above and no other.
renderer drops it. The unit's sandbox settings (`MemoryDenyWriteExecute`,
`SystemCallFilter` and the rest) stay on the host: the pod has the security
shape above and no other.
- **Network:** a service whose entry has `egress` (`swarm-stt`) gets a
NetworkPolicy named after it, selecting its pods for ingress and egress. It
allows no ingress; its egress is cluster DNS (the CoreDNS pod, port 53) and,