feat/tenants-table-polish #86

Merged
clawdie merged 2 commits from feat/tenants-table-polish into main 2026-06-19 21:41:45 +02:00
Owner
No description provided.
clawdie added 2 commits 2026-06-19 21:41:31 +02:00
feat(store): tenants table — 1:1:1 map for colibri-vault provision
Some checks failed
CI / rust (pull_request) Has been cancelled
CI / markdown (pull_request) Has been cancelled
6b16281e05
- schema.rs: CREATE TABLE tenants (tenant_id, jail_root_path, collection_id, status)
- lib.rs: Tenant struct + register_tenant/list_tenants/get_tenant/set_tenant_status
- FreeBSD: jail_root_path = /usr/local/bastille/jails/<name>/root
- Linux: jail_root_path = container volume path (portable column)
- Step 2 of HIVE-ONBOARDING plan
fix(store): polish tenants table — UNIQUE constraints + export + tests
Some checks failed
CI / rust (pull_request) Has been cancelled
CI / markdown (pull_request) Has been cancelled
7da32bafe9
- Add UNIQUE on jail_root_path and collection_id to enforce
  the 1:1:1 contract at the schema level
- Include tenants in export_json() so parity diffs are complete
- Add test_tenant_lifecycle: register → get → status transitions
  through full lifecycle (provisioned → active → stopped →
  destroyed) + NotFound errors
- Add test_tenant_uniqueness: duplicate path and collection
  rejected with UNIQUE constraint violations
- Extend test_export_json to assert tenants array present

All 9 store tests pass, full suite green.
clawdie merged commit 8ab4bf131d into main 2026-06-19 21:41:45 +02:00
clawdie deleted branch feat/tenants-table-polish 2026-06-19 21:41:46 +02:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: clawdie/colibri#86
No description provided.