| 1 | --- |
| 2 | type: decision |
| 3 | id: dcr-9b5da04 |
| 4 | status: decided |
| 5 | title: Hosts serve valleys; valleys on a shared host are strongly isolated |
| 6 | created: 2026-08-22 |
| 7 | source: design conversation, 2026-08-22 |
| 8 | supersedes: [dcr-2f03be3] |
| 9 | --- |
| 10 | |
| 11 | # Hosts serve valleys; valleys on a shared host are strongly isolated |
| 12 | |
| 13 | **Decided 2026-08-22.** Supersedes [[dcr-2f03be3]] |
| 14 | ([dcr-2f03be3-hosts-serve-isolated-groups.md](./dcr-2f03be3-hosts-serve-isolated-groups.md)). |
| 15 | |
| 16 | A host is shared infrastructure. Host and valley stand in an N : M relation, and the two directions |
| 17 | are not equally near: a host serving several valleys is present intent and is what the machinery is |
| 18 | built for, while a valley spanning several hosts is unprecluded and deferred. Replication stays |
| 19 | backup-depth until a rung of the ladder asks for more ([[dcr-d7952bc]] |
| 20 | ([dcr-d7952bc-phase0-replication-github-transitional.md](./dcr-d7952bc-phase0-replication-github-transitional.md))). |
| 21 | Every project has exactly one owning valley, which is the valley whose floor and registry govern it. |
| 22 | |
| 23 | ## Strong isolation between valleys on a host |
| 24 | |
| 25 | Two valleys on one host are separated as strongly as the mechanisms allow. As long as git access |
| 26 | over ssh rides the unix user model, the users are per valley: each valley has its own push user, and |
| 27 | that user's `authorized_keys` is compiled from that valley's registry alone. No compiled artifact is |
| 28 | ever a union across valleys, so a valley's blast radius is its own user. The ssh user is the valley |
| 29 | selector — it is what a clone URL names to reach one valley's repositories rather than another's. |
| 30 | Repositories and service state split per valley on the same principle, and the service split of |
| 31 | [[bd-500adf7]] ([bd-500adf7-bus-shares-git-user.md](../bugs/bd-500adf7-bus-shares-git-user.md)) |
| 32 | extends valley-wise: what earns a user of its own earns one per valley. |
| 33 | |
| 34 | Cross-valley event visibility is not a default. How the bus provides valley scoping — one bus per |
| 35 | valley, or one bus with authenticated valley-scoped subjects — is open |
| 36 | ([openquestions.md](../../design/openquestions.md)). |
| 37 | |
| 38 | ## An identity may belong to several valleys |
| 39 | |
| 40 | The same person, machine, or service may act in more than one valley. Each valley's registry cites |
| 41 | the identity's keys independently and decides for itself what they may do there. Nothing is minted |
| 42 | once and shared: this is the cited-not-minted shape of [[dcr-b87f6e8]] |
| 43 | ([dcr-b87f6e8-identity-is-a-governed-registry.md](./dcr-b87f6e8-identity-is-a-governed-registry.md)), |
| 44 | applied between valleys on one host rather than across an organizational boundary. |
| 45 | |
| 46 | ## One integrator principal per valley |
| 47 | |
| 48 | Each valley's registry declares one integrator principal, and every controller the valley runs signs |
| 49 | as it. Controllers are processes, not identities — a valley with many protected projects runs many |
| 50 | controllers under one principal. A principal already holds several keys, so a valley whose |
| 51 | controllers run on more than one host needs nothing new. |
| 52 | |
| 53 | ## Registry compilation refuses to orphan governance |
| 54 | |
| 55 | A registry state that leaves no non-expired key holding governance of the registry's own stream is |
| 56 | invalid, and compilation refuses to render it. An invalid render never touches the last-good |
| 57 | artifacts, so a valley cannot lock itself out of its own governance by landing a change whose only |
| 58 | effect is arrived at later, when the last governing key expires. |
| 59 | |
| 60 | ## The host declaration, and what isolation is not |
| 61 | |
| 62 | The host declaration is content in the repository of the valley that owns the host: a host is |
| 63 | declared by a valley, like any other thing a valley is responsible for. |
| 64 | |
| 65 | Isolation is between peer valleys, not from the valley that owns the host. Root on the host sees |
| 66 | everything on it, and no arrangement of unix users changes that. A valley that requires independence |
| 67 | from the owner of the machine it runs on wants federation ([[ida-8482624]] |
| 68 | ([ida-8482624-federation-groups.md](../ideas/ida-8482624-federation-groups.md))) — its own host, |
| 69 | peered — and that is the eventual answer, not a stronger separation within one machine. |
| 70 | |
| 71 | ## Open |
| 72 | |
| 73 | - The bus's valley scoping, gated on bus authentication ([[bd-d853d9c]] |
| 74 | ([bd-d853d9c-bus-unauthenticated.md](../bugs/bd-d853d9c-bus-unauthenticated.md))). |
| 75 | - Per-valley user naming and filesystem layout, and which services beyond the push boundary split |
| 76 | per valley. The isolation principle answers the last of those in the affirmative; the mechanics |
| 77 | are designed when the second valley on a host arrives. |
| 78 | |
| 79 | ## Related |
| 80 | |
| 81 | - [[dcr-8f069dd]] ([dcr-8f069dd-valley-is-the-unit.md](./dcr-8f069dd-valley-is-the-unit.md)) — the |
| 82 | unit this decision is about. |
| 83 | - [[dcr-b87f6e8]] |
| 84 | ([dcr-b87f6e8-identity-is-a-governed-registry.md](./dcr-b87f6e8-identity-is-a-governed-registry.md)) |
| 85 | — the registry each valley's push boundary compiles from. |
| 86 | - [[bd-500adf7]] ([bd-500adf7-bus-shares-git-user.md](../bugs/bd-500adf7-bus-shares-git-user.md)) — |
| 87 | the service split this extends valley-wise. |
| 88 | - [[ida-8482624]] ([ida-8482624-federation-groups.md](../ideas/ida-8482624-federation-groups.md)) — |
| 89 | the layer above, and where a valley that wants independence from a host owner goes. |