Files
hq/03-DESIGN/01-to-be
jschoubben 5d1e6d0b09 Design: building a module, and why the recipe cannot always be a Dockerfile
12-a-module-repository says what a module may build and where it goes. Nothing
said how a build is MODELLED, and the model is the problem: a recipe is implicit,
singular and always a Dockerfile; a toolchain is not modelled at all, arriving as
two build arguments the module hand-writes; a language is not a concept; and an
archive is declared in the manifest and refused by the builder.

The cost is measurable rather than theoretical. Adding a module with its own code
means repeating an incantation - two ARG bases, a specific working directory so
the SDK resolves upward, the compiler invoked by absolute path because the usual
symlink is resolved away when the base is assembled, a second stage, an env var
naming the entrypoints. Most of the catalogue is unconverted, and two conversions
done in one session were each wrong twice with a working example open.

So: recipe becomes explicit with three kinds, and toolchain becomes derived from
a declared language rather than written by every author. A Dockerfile stays, and
stops being compulsory - it is right for software needing a particular base and
wrong for "compile my module's code", which is the same operation every time.

The cost is stated before it is chosen: every language is permanent, and the
contracts are already expressed twice - Go structs and TypeScript types kept in
step by hand. A second language makes that drift. So language-neutral contracts
come first, or the drift gets worse while hiding.

Claude-Session: https://claude.ai/code/session_01D6qtiYU3P9jk3pnAXyAFyx
2026-09-15 01:51:42 +02:00
..

03-DESIGN / 01-to-be

The mesh being built toward. Every statement here traces to a record in 02-DECISIONS/; nothing arrives by drafting.

A document here describes an intention. What currently runs is in 00-as-is/, and the two are never merged — when something ships, the as-is document is written and this one's status becomes implemented.

Document Covers Rests on
00-work-breakdown.md How modules move across one at a time, until the old registry can be switched off ADR 0001, ADR 0016
01-end-to-end-testing.md The lab: a real mesh a change can be run against before it reaches nodes ADR 0016, 0029
02-scenario-declaration.md What a scenario declares — the underlay, and what to place on it ADR 0016
03-scenario-lifecycle.md What happens to a scenario — raise, snapshot, restore, move, destroy ADR 0016
04-lab-installation.md Getting the lab onto a clean machine, and why it verifies capability rather than installation ADR 0010
05-the-node-host.md Tier 0 — the one thing installed by hand, and the only thing that changes a machine ADR 0005
06-the-control-plane.md Tier 2 — what the term means, and the test for what belongs in it ADR 0005
07-the-substrate.md Tier 1 — what the control plane consumes and cannot grant itself ADR 0004, 0048
08-connectivity.md One context in full — overlay, resolution, exposure, filtering, certificates ADR 0007, 0050, 0051, 0055
09-the-node-lifecycle.md How a machine becomes a node, stays one, and stops being one ADR 0004, 0051
10-delivery.md Modules, the three edges, and how a change becomes a running thing ADR 0010, 0064, 0065
11-a-board.md What a person sees of the mesh, and why it is read from what runs ADR 0008, ADR 0001
12-a-module-repository.md A module repository, and what builds it ADR 0009, ADR 0010, ADR 0005
13-credentials-and-their-rotation.md Credentials, and moving them without a consumer holding one the provider does not know about ADR 0001, ADR 0009
14-model-access.md Model access as a provision, and what a licence is bound to ADR 0024, ADR 0009
15-the-agent-session.md One mechanism started twice — a node's session and the mesh's ADR 0004, ADR 0026
16-module-coverage.md What a module must be able to say, measured against 127 that exist ADR 0009, ADR 0005
17-raising-a-mesh.md How a mesh comes into existence, and how a machine joins one that exists ADR 0067, ADR 0006, ADR 0005
18-building-a-module.md How a build is modelled, and why a recipe that is always a Dockerfile does not fit what a module is ADR 0040, ADR 0039, ADR 0009

Not yet written

  • The remaining six contexts. ADR 0006 settles the list at seven; connectivity is the first written in full (08) and the other six do not exist yet. The work breakdown says in what order they are needed.
  • Domain grouping outside the core. Not needed. ADR 0009 is superseded by ADR 0009: there is no domain module to group into, so there is no domain list to settle. Relationships are edges, and grouping is a tag and a query.