zalando / zalando/postgres-operator
[CORE] Unable to set kubernetes pod container securityContext for allowPrivilegeEscalation: false in postgres pod exporter sidecar container
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 5.2k
- Forks
- 1.1k
- Avg merge
- 2d 16h
- Merged PRs (30d)
- 3
Description
Please, answer some short questions which should help us to understand your problem / question better?
- Which image of the operator are you using? - registry.opensource.zalan.do/acid/postgres-operator:v1.7.1-17
- Where do you run it - cloud or metal? Kubernetes or OpenShift? - [ Azure AKS ]
- Are you running Postgres Operator in production? [ no ]
- Type of issue? [Bug report]
[CORE] Unable to set kubernetes pod container securityContext for allowPrivilegeEscalation: false in postgres pod exporter sidecar container.
Azure AKS policy - https://store.policy.core.windows.net/kubernetes/container-no-privilege-escalation/v3/template.yaml is blocking containers as postgres pod is running with configuration ( spilo runAsUser: 101 )
Warning FailedCreate 23s (x86 over 14h) statefulset-controller create Pod postgres-operator-cluster-0 in StatefulSet postgres-operator-cluster failed error: admission webhook "validation.gatekeeper.sh" denied the request: [azurepolicy-k8sazurev3noprivilegeescalatio-ed466999daa0a417e688] Privilege escalation container is not allowed: exporter
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names the PostgreSQL pod's exporter sidecar but no source file or test. Start by tracing how the operator generates that container and its securityContext, then reproduce the AKS admission rejection; done means the generated pod satisfies the requested no-privilege-escalation policy.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- kubernetes, postgresql
- Domain
- databases, infrastructure, security
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100