A chart from the internet requests cluster-admin. How do you evaluate and contain it?
AdvancedScenarioSecrets & Security
Answer
Situation read → Many charts over-request RBAC.
What I'd do →
helm templateand review every ClusterRole/Role and binding.- Check whether namespaced mode exists (
rbac.clusterWide: false,watchNamespace). - If not, replace with a reduced ClusterRole via values or a post-renderer.
- Install in a dedicated namespace with NetworkPolicies, Pod Security restricted, and image signature verification.
Why → Rendered output tells you exactly what you are granting.
Interview tip → Always review rendered RBAC before installing third-party charts.
More on Secrets & Security
A secret was committed in plaintext in `values-prod.yaml`. What do you do?BeginnerWho can read secrets passed to Helm, and how do you reduce exposure?IntermediateSet up helm-secrets with SOPS and AWS KMS for prod and age for dev.IntermediateYour security team asks you to scan Helm charts for misconfigurations in CI. How?BeginnerHow do you rotate a database password managed through Helm without downtime?AdvancedYour CI service account for Helm has cluster-admin "because it was easier". How do you fix it?Intermediate