I am trying to deploy to a kubernetes cluster an umbrella chart that contains the rabbitmq operator + rabbitmq. So in total 2 sub-charts.
The operator sub-chart first deploys the CRD needed "kind: RabbitmqCluster" for the rabbitmq sub-chart and everything is installed correctly when I install the umbrella chart. I see 2 containers, the operator and an instance of rabbitmq.
The problem arises when I want to uninstall the umbrella chart (
helm uninstall...), the rabbit operator is removed (since it has a "kind: Deployment") but not the rabbitmq instance that it has created. To do so, I need to manually run
kubectl delete rabbitmqcluster name of instance.
Is there a way to do so when the helm uninstall is run or am I barking up the wrong tree?