Interview Prep/DevSecOps/Kubernetes admission control and Pod Security

A policy requiring resource limits blocks Istio-injected pods because the sidecar has no limits

IntermediateTroubleshootingKubernetes admission control and Pod Security
Answer

Likely causes → Mutating webhooks (Istio) run before validating ones; the injected istio-proxy container fails your validation.

Diagnose → kubectl get events shows the container name istio-proxy in the denial.

Fix → Set sidecar resources via the mesh config or pod annotations (sidecar.istio.io/proxyCPULimit), or scope the policy to exclude that container by name with a documented reason.

Prevent → Test policies against fully mutated pods (server-side dry-run: kubectl apply --dry-run=server).

All DevSecOps questions Roadmap: Policy as code

More on Kubernetes admission control and Pod Security