puppet: reduce privilege in namespace workloads (#307) #319
Reference in New Issue
Block a user
Delete Branch "benvin/puppet-rootless"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Why: shrink the blast radius of the Puppet control-plane pods (CA/eyaml keys, compiled catalogs) per the security sweep in #307 — remove root where it is not required and strip cargo-culted capabilities.
How:
chown -R 1000:1000(PVC now group-owned).chown 999:999.Stays root (evidence-backed, class-B fallback): the puppetserver master/compiler and puppetdb main containers, plus the perms-and-dirs and generate-types root containers. The OpenVox image entrypoint runs
chown -R puppet:puppetover root-owned baked-in dirs and drops the JVM to the puppet user viarunuser(needs CHOWN/SETUID/SETGID); a non-root start crashloops. Their cap sets are reduced to the minimum justified (CHOWN/DAC_OVERRIDE/FOWNER[/SETUID/SETGID]).Validation:
kustomize build --enable-helmclean; kubeconform 0 invalid / 0 errors; pre-commit (yamllint etc.) green. Confirmed against live pods: puppetserver/puppetdb JVMs already run as puppet/puppetdb viarunuser;pam_loginuidis absent from the su/runuser PAM stacks and loginuid is unset, so dropping AUDIT_WRITE is safe.Post-merge smoke test (puppet had an outage this session — watch closely): after argocd sync, confirm puppetserver master + a compiler reach
runningat /status/v1/simple, puppetdb reachesrunning, puppetboard serves 200, and the generate-types + g10k CronJobs complete — i.e. catalogs still compile and reports still ingest.Closes #307
https://claude.ai/code/session_015ur3i7D2azsMAWTSVABApv
cd6a596c92to381734a9c7