A worker container runs under the seccomp profile the chart chooses, by default the chart's own Localhost profile (the runtime's default plus the namespaces bubblewrap makes) put on every node by a DaemonSet that mounts that one directory, and a worker pod runs in a user namespace of its own with its /proc unmasked, so bubblewrap can mount the sandbox's own; kind uses Unconfined¶
Decision 890 · accepted · 2026-10-12 · issue #690 · supersedes 832
Decision 832 and D104 took this for a node setting ("unprivileged user namespaces off ... needs its security profile changed"); the node allowed them, and the pod's own profile was what refused. This replaces that part of 832 and nothing else: the refusal, the sentence and the log line stay as 832 has them.
- A chart value chooses.
worker.seccomp.typeisLocalhost,RuntimeDefaultorUnconfined, withlocalhostProfilethe path under the kubelet's seccomp directory. The chart gives it to the operator (TROUPE_WORKER_SECCOMP_TYPE,TROUPE_WORKER_SECCOMP_PROFILE), which puts it on the worker container; the pod's ownsecurityContextkeepsRuntimeDefault, so anything else a pod ever runs beside the worker does not inherit the wider profile. It is the installation's, not a profile's, for the reason the rest ofSettingsis: a profile that could chooseUnconfinedwould be one somebody would choose. The chart refuses another type, aLocalhostwithout a path, and a path any part of which does not start with a letter or a digit (so..never takes the installer's mount out of the kubelet's directory);config/runtime.exsrefuses the first two again when the operator starts. Localhostby default, with the chart's profile.charts/troupe/files/worker-seccomp.jsonis containerd 2.1's default profile as it renders for a container with every capability dropped (read from the OCI spec of such a container on kind, v1.34, containerd 2.1.3), for the x86 architectures the images are built for, with three changes and nothing else:cloneis allowed with a user, mount, PID, IPC or UTS namespace flag where the default allows none (the rule's mask isCLONE_NEWNET | CLONE_NEWCGROUPwhere it was every namespace flag);unshareis allowed with the same flags (mask alsoCLONE_NEWTIME; bubblewrap calls it for its second user namespace, since--devmounts a devpts); andmount,umount2andpivot_rootare allowed, which a process without capabilities can use only inside a user namespace it made itself. A network, cgroup or time namespace is still refused, as is everything else the default refuses (setns,bpf,keyctl,perf_event_open, the io_uring calls and the new mount API among them;clone3still answers ENOSYS, socloneis what is used). No network namespace matters most: one a process owns would give itCAP_NET_ADMINover netfilter there, where many user-namespace kernel exploits begin, and the sandbox does not unshare the network (Cilium's policy is the pod's).- Put on the nodes by a DaemonSet (
templates/worker-seccomp.yaml, on withworker.seccomp.install.enabledandtype: Localhost). The profile is a ConfigMap; one pod per node copies it to<kubeletSeccompDir>/<localhostProfile>(written beside and renamed, so the kubelet never reads half), then sleeps, ready while the file matches. A worker pod that lands on a node before the file is there failsCreateContainerError("cannot load seccomp profile") and starts once it is. - The Security Profiles Operator where a cluster runs one:
install.enabled: false, the same rules as aSeccompProfile's spec introupe-system, andlocalhostProfilethe path it installs it at,operator/troupe-system/<name>.json. Nodes built with the file are the same with no operator at all. Unconfinedon kind (dev/kind/values.yaml). A cluster that is thrown away needs no node installer, and its worker namespaces areprivileged. Never in production: it is no syscall filter at all.RuntimeDefaultstays a choice: workers start, keep the runtime's filter, and refuse every command with 832's sentence. It is also what the operator uses when nothing sets the variable, so an operator without the chart fails closed, as 832 wants.- The profile is needed and not enough: a user namespace for each worker pod, with its
/procunmasked. The runtime masks paths under a container's/proc(/proc/kcoreand others, mounted over,/proc/sysread-only), and the kernel refuses a new proc mount in a user namespace while the one it would reveal is not fully visible. Kubernetes unmasks a container's/proc(procMount: Unmasked) only for a pod in a user namespace of its own (hostUsers: false), where the container's root, and every other uid in it, is an unprivileged user on the node.worker.userNamespaces(defaulttrue) makes the operator write both,hostUsers: falseon the worker pod andprocMount: Unmaskedon the worker container, from the one setting (TROUPE_WORKER_USER_NAMESPACES), so an unmasked/procoutside a user namespace is never rendered; the chart refuses a value that is not a boolean, since the string"false"reads as on.false, and an operator that is not told, keep today's pod: it starts, and refuses every command with 832's sentence. Chosen over a sandbox with no fresh/proc(an empty one breaks the tools a shell uses, and the pod's own would show the worker's processes and their environment to a command running as the same user) and over a privileged container. - What user namespaces need. Kubernetes 1.33 or later (user namespaces on by default;
procMountis kept, which it is on 1.34 with no feature gate set), containerd 2.0 or later with runc 1.2 or later, Linux 6.3 or later on the nodes (idmapped tmpfs, which the projected tokens and ConfigMaps are), and storage whose filesystems take idmapped mounts: a block volume with ext4 or xfs, and kind's local-path directories, do. NFS does not, and most RWX file storage is NFS: a team volume there is expected to keep its pod from starting, with the idmapped mount refused in the pod's events (not tried here). A cluster that cannot setsworker.userNamespaces: falseand its workers run no command until it can. - Pod Security. The operator labels no worker namespace, so they have the cluster's
default level.
baselineandrestrictedrefuseprocMount: Unmaskedeven in a user namespace (checked on 1.34), as they refuseUnconfined, so worker namespaces needprivileged;LocalhostandRuntimeDefaultalone passrestricted, as the rest of the worker pod does. The chart cannot refuse the combination: the namespaces are made after it renders and take a level from the API server's admission configuration, which nothing can read through the API. Such a cluster refuses every worker pod at creation, in aFailedCreateevent on the StatefulSet that names the field. The installer's DaemonSet mounts a host directory and runs as root, so its own namespace needsprivilegedtoo. - Upgrading a plane that runs workers changes every profile's pod template: each
reports
UpgradePendingand its pods are replaced as they empty (Decision 726). WithLocalhostthe installer has to be ready first, which it is unless a node is missing, and the worker namespaces needprivilegedbefore the replacements are made, or the StatefulSet cannot create them. - Not chosen.
Unconfinedin production: the sandbox would start, with no filter around it.CAP_SYS_ADMINon the worker: it lets the default profile allow everything this does and far more, mounting in the pod's own namespace among it. A profile per profile: one pod's needs are every pod's. Docker's form of the default, with rules that hold only for some capabilities (includes.caps): a file cannot know a container's capabilities, the worker's are always none, and the form containerd renders itself, the OCI runtime spec's, is the one it was proven in.
Governs: apps/troupe_operator/lib/troupe/operator/settings.ex, apps/troupe_operator/lib/troupe/operator/resources.ex, charts/troupe/templates/worker-profiles.yaml