0

I am new to k8s and helm. I am deploying an open source distributed software called zeebe that provides helm charts for k8s deployment. I have seen that even after executing the helm uninstall command the persistent volume claims and persistent volumes do not get deleted.

A workaround is stated on this helm github issue to define a helm hook. Being new to helm I cannot find an example to try this out. The only file that I have been editing so far when installing and uninstalling helm chart is the values.yaml file. Kindly guide me on how and where to write an helm hook for zeebe deployment to delete its persistent volumes on helm uninstall.

Thanks.

Andy Dufresne
  • 6,022
  • 7
  • 63
  • 113
  • You'd add the hook Job to a file in the chart's `templates` directory, like any other Kubernetes resource. Note that, if the PVC is indirectly created through a StatefulSet, Helm may not have direct knowledge of it. Is there a specific problem you're running into with this setup? What code have you written so far? – David Maze Jan 30 '23 at 14:29

1 Answers1

1

I finally found a solution to this. All pv and pvc could be deleted through kubectl delete pvc -l app=camunda-platform command

Andy Dufresne
  • 6,022
  • 7
  • 63
  • 113