mirror of
https://github.com/cozystack/cozystack.git
synced 2026-11-03 18:47:04 +09:00
Whoever orders GPUClaim objects must not touch two parts of a claim. The claim finalizer keeps a released claim, its binding and its usage record until no VMI uses it, so a tenant who could drop it could take a held claim out of the usage records. The template-claim label is the mark the GPU controller sets on claims it creates from a claimTemplate, and it deletes claims so marked with their VMI, so on a tenant's own order it would get that order deleted. Both are refused for everyone but platform callers, matched by group like the other cozystack-basics policies: cozy-system and kube-system service accounts and cluster admins, plus kube-controller-manager, which has no group of its own. The orphan and foregroundDeletion finalizers belong to the API server and the garbage collector and stay free. Assisted-by: LLM Signed-off-by: Aleksei Sviridkin <f@lex.la>