# Unit of Work Dependency — atheos-blog-lxc **Stage**: INCEPTION — Units Generation (Part 2) ## Dependency matrix Rows *depend on* columns. | | U1 Guest | U2 Web stack | U3 Atheos | U4 Git+clone | U5 Docs | |---|---|---|---|---|---| | **U1 Guest** | — | — | — | — | — | | **U2 Web stack** | ✔ | — | — | — | — | | **U3 Atheos** | ✔ | ✔ | — | — | — | | **U4 Git+clone** | ✔ (git) | — | ✔ (workspace) | — | — | | **U5 Docs** | ✔ | ✔ | ✔ | ✔ | — | ## Build order ``` U1 ──► U2 ──► U3 ──► U4 ──► U5 │ ▲ │ └─────────────────┴────────┘ (U4 needs git from U1) ``` **Critical path**: U1 → U2 → U3 → U4 → U5. Strictly sequential — no parallelism worth the coordination cost at this size. Each unit already includes a verification step, so a failure is caught at unit granularity rather than at the end. ## Why these boundaries | Boundary | Reason | |---|---| | U1 before everything | nothing can be installed without the guest | | U2 (nginx+php) is one unit, not two | the **socket contract (I-1)** spans both — splitting them would create a boundary through a single interface, which is exactly where integration bugs live | | U3 after U2 | Atheos has nothing to run on until PHP exists | | U4 separate from U3 | **different failure class**: U3 is PHP-runtime risk (C-1); U4 is VCS/permissions risk. Separating them keeps a U3 failure from disguising itself as "git is broken" | | U4 before U5 | the RUNBOOK must document the real remote command, which only exists after the clone | | U5 last | docs describe what was actually built | ## Cross-unit risks | Risk | Units | Note | |---|---|---| | FPM user identity | U2 → U3 → U4 | U2 resolves the run user; U3 sets ownership; U4 owns the key. **All three must agree on the same user** — a mismatch yields "dubious ownership" (I-3) | | FPM socket path | U2 (internal) | must match across nginx + pool | | Pinned Atheos SHA | U3 → U5 | U5's update script must re-pin the same mechanism | | Remote URL | U4 → U5 | U5 documents it; U4 must not change it to SSH |