reactive-tech / kubegres

Kubegres is a Kubernetes operator allowing to deploy one or many clusters of PostgreSql instances and manage databases replication, failover and backup.
https://www.kubegres.io
Apache License 2.0
1.32k stars 74 forks source link

Delete pvc when pod is deleted #71

Closed owenchenxy closed 2 years ago

owenchenxy commented 3 years ago

hi Alex,

currently, while a failover happend, a new pvc will be created along will the new replica pod. However, the old pvc remained even though the old replica pod is deleted. If there are frequent failover happens somehow, there will be lots of pvcs, which could run out the storage.

Could you make some improvement, so that the pvc will be deleted along with the deleted pod?

leonz commented 2 years ago

We just noticed this as well and it is causing major problems for us.

alex-arica commented 2 years ago

Thank you both for your feedback. There is a ticket about the issue that you reported: #20 I am going to prioritise it but I cannot commit to any dates.

Note that if it is urgent and someone from the community decides to implement it and send me a PR, I will be happy to review it asap.

alex-arica commented 2 years ago

I am closing this issue as it is a duplicate of #20