Closed GrahamDumpleton closed 2 years ago
@GrahamDumpleton thanks for creating this issue! Yes we should definitely make vcluster statefulset independent and not provide any features that specifically require a statefulset, maybe even just use a flag --set-owner
that will find out the owning resource automatically based on the current pod.
This should work now with the new v0.4.4 and up
As per old discussion at:
https://loft-sh.slack.com/archives/C01N273CF4P/p1633429533205300
it may be beneficial in some cases to use a Deployment for the syncer rather than a StatefulSet. One reason being that the persistent volume will be automatically deleted when deleting the Deployment (if using owner references) but not when using a StatefulSet.
The issue with using a Deployment is the
--owning-statefulset
option is designed on basis that a StatefulSet is used. To support use of Deployment, this would need to be generalised so could specify a type for the owner of Deployment or StatefulSet. Eg.,--owning-resource=deployment/vcluster
or--owning-resource=statefulset/vcluster
.