A CRD was deleted and all custom resources disappeared. How do you prevent that?
AdvancedScenarioHelm, operators and GitOps
Answer
Situation read → Someone uninstalled an operator chart and the data objects vanished.
What I'd do →
- Explain that deleting a CRD deletes all its objects
- Helm does not manage CRDs in
crds/on upgrade or uninstall - Install CRDs separately and protect with RBAC
- Back up with Velero or GitOps
- Add admission policy blocking CRD deletion
Why → CRD deletion is cascading and immediate.
Interview tip → Memorise this as a favourite gotcha.
More on Helm, operators and GitOps
A `helm upgrade` failed halfway. How do you see state and recover?BeginnerHelm says `cannot re-use a name that is still in use` or `another operation is in progress`. What now?IntermediateHow do you review what a Helm upgrade will change before running it?IntermediateWhere do you keep chart values for multiple environments?BeginnerWhat does `helm template` do and how is it different from `helm install`?BeginnerA Helm chart upgrade changed an immutable field and failed. How do you proceed?Advanced