mirror of
https://github.com/cozystack/cozystack.git
synced 2026-11-21 20:23:39 +09:00
An application write in the Cozystack API kept several objects in step, which needed a cross-replica Lease lock and kept producing races. The accepted design (cozystack/community#137) moves the account list to the chart: it renders a CredentialTemplate per account, a controller in cozystack-controller seeds, adopts and mirrors the account Secret, and an API request writes at most one object. The ApplicationDefinition credentials block, the account resolvers, the lock and its Lease grant, and the seeding and pruning in the application registry go. The Credential view reads templates only, and mint and revoke build the whole Secret from the template and write it under the Secret version the template's status mirrors. The API marks the releases it creates for seeding and keeps the controller's valuesFrom entries on an update, and so does the ApplicationDefinition reconciler. Assisted-by: LLM Signed-off-by: Andrei Kvapil <kvapss@gmail.com>