filecoin-project / dealbot

🤖🤝 A bot for making deals
Apache License 2.0
32 stars 10 forks source link

Dealbot does not remove pvc volumes when deleting dealbots #418

Open travisperson opened 2 years ago

travisperson commented 2 years ago

Dealbot uses the lotus-bundle helm-chart when setting up dealbot lotus daemons.

Statefulsets do not clean up pvc resources and it's left up to the administrator to remove these volumes. Dealbot currently does not handle the deleting of the pvc after uninstalling the helm chart, and helm does not support deleting pvc from statefulsets either (https://github.com/helm/helm/issues/5156)

https://github.com/filecoin-project/dealbot/blob/3f74c43cf658f0cc2da62ed3fcc6b8ac9ece0cf3/controller/spawn/kubernetes.go#L85-L97

There is no way to delete the volume automatically. In k8s v1.23 there is an alpha feature to allow for this change. However, we will not be able to use this feature.

Dealbot will need to manually execute a delete action against the pvc for the lotus-bundle helm chart to clean up these volumes.