Files
cozystack/pkg
Aleksei Sviridkin a883541176 feat(api): refuse raw GPU quota keys when raw names are forbidden
With gpu.rawResourceNames set to forbidden, GPUs reach tenants only as
GPUClaims, budgeted by gpu.cozystack.io keys. A hoster sets it only
once no quota key on a GPU resource name itself is left, and tenant
validation now keeps it that way: a raw GPU key, bare or as
requests.* or limits.*, is refused, so nobody can bring the old
budget form back.

The setting and the effective GPU resource-name set are read from the
settings ConfigMap the controller writes, through the uncached client
the API already uses for quota reads, so the Deployment needs no new
flags. Without the ConfigMap raw names stay allowed. The read happens
only when the tenant declares a key that can be a resource name.

Assisted-by: LLM
Signed-off-by: Aleksei Sviridkin <f@lex.la>
2026-10-23 03:53:34 +03:00
..