--- type: journal project: homelab date: 2026-09-27 tags: - homelab - architecture - curation - gitops - appctl - roadmap --- # Daily Journal: 2026-09-27 ## Wins ### Homelab Architecture Consolidation Roadmap v3 & Guide Promotion - Formally curated and promoted **Homelab Architecture Consolidation & Hardening Roadmap v3** and **Implementation Guide v3** to the canonical knowledge graph: - [`projects/homelab/plans/architecture-consolidation-roadmap-v3.md`](../../projects/homelab/plans/architecture-consolidation-roadmap-v3.md) - [`projects/homelab/plans/architecture-consolidation-implementation-guide-v3.md`](../../projects/homelab/plans/architecture-consolidation-implementation-guide-v3.md) - Re-baselined the platform architecture against commit `246b587` (NixOS appliance, Portainer deprecation, Stalwart mail & SMTPS submission, Dozzle forward-proxy auth, Diun jitter/workers, and 35 invariant tests). - Codified the 5-tier service taxonomy: Host Foundation, Edge & Security Primitives, Core Platform Capabilities, Platform Operations, and Workloads (Sites). - Codified the Controller Authority Matrix and Resource & State Ownership Matrix, resolving multi-controller ambiguities across systemd, Core Compose, GitOps, and `appctl`. - Inverted the GitOps trust boundary: admissions are authoritatively driven by `Core/config/deployments.yaml` instead of workload manifests claiming aliases. - Isolated Second Brain (`~/Brain`) as a strictly read-only data vault (`strategy: pull-only`), completely stripped of Docker socket access and container lifecycle capabilities. - Added workload Compose policy validation to treat untrusted Compose files as a capability attack surface. - Archived superseded Roadmap v2 and Implementation Guide v2 into [`projects/homelab/archive/`](../../projects/homelab/archive/) with updated backlinks in past journals (`2026-09-13`, `2026-09-14`) and project landing pages. ### Dual-Track Boundary Lock & P3 Convergence Runbook - Synchronized cross-track coordination between **Track A** (Architecture on `main`) and **Track B** (`appctl-v2` in `~/Projects/active/appctl-refactor` on `refactor/appctl-rework`). - Codified the 5 stable architectural seams protected by `appctl-v2` until convergence: 1. **CLI Syntax**: Caller flags, subcommands (`list`, `info`, `up`, `down`, `sync`), and exit codes remain identical. 2. **`resolve` JSON Contract**: `cmd_resolve` schema guarantee (`name`, `dir_path`, `type`, `domain`, `container`, `env`) verified via automated test fixtures. 3. **Canonical Identity**: Unified service identifiers across platforms. 4. **Core vs. Sites Taxonomy**: Platform capabilities strictly separated from workloads. 5. **Homepage Sync Semantics**: Unbroken `services.yaml` compilation from Core inventory + Sites manifests. - Defined symmetrical P1 isolation rules: minimal legacy patch to `Core/scripts/appctl_engine.py` on `main` (Stalwart domain to `smtp.roadtotech.me`, remove `snappymail`), while Track B applies the identical semantic change directly to its typed `CoreService` model without branch cross-merging. - Established the concrete 6-step P3 convergence sequence: `main` authors `core_manifest.py`, Track B cherry-picks the isolated contract commit, adapts `appctl_engine_v2.py`, runs hermetic test verification, promotes `appctl_engine_v2.py` to `appctl_engine.py`, and merges into `main` with full regression verification (`./scripts/test` and `nix flake check`). ### Architectural Planning Freeze & Transition to Implementation - Formally declared an end to architectural revision cycles across Homelab Core documentation. - The guides are now the authoritative source of truth. Implementation of Phase 1 (Mail Topology Realignment) is cleared to begin. - Implementation-level issues encountered during rollout will be addressed directly in code unless an underlying architectural assumption in the frozen guides is proven invalid. --- ## Planning & Specifications - [Architecture Consolidation & Hardening Roadmap v3](../../projects/homelab/plans/architecture-consolidation-roadmap-v3.md) - Canonical 5-tier architecture, authority matrices, inverted GitOps registry, mail topology realignment, and platform readiness contracts. - [Architecture Consolidation Implementation Guide v3](../../projects/homelab/plans/architecture-consolidation-implementation-guide-v3.md) - Executable step-by-step phased runbooks, zero-data-loss SnappyMail migration gates, and P3 controlled convergence procedure. - [appctl Engine V2 Refactoring Plan](../../projects/homelab/plans/appctl/appctl-engine-v2-refactoring.md) - Modernization of `appctl` into a typed, test-driven engine, aligned with the 5 integration seams and P3 cherry-pick runbook. --- ## Architecture & Design Decisions ### Strict Direction of Integration (`main` $\rightarrow$ `refactor/appctl-rework` $\rightarrow$ `main`) Treating `appctl-v2` as a hard prerequisite for Phase 1 and Phase 2 would stall necessary infrastructure realignments (mail domain migration, GitOps sandboxing). Conversely, continuous bidirectional merging between `main` and the refactor branch risks thrashing and merge conflicts in rapidly changing files. By adopting a strict one-way contract flow—authoring `core_manifest.py` on `main`, cherry-picking only the contract commit into the worktree, adapting and verifying hermetically, promoting the file, and then merging back to `main`—both tracks maintain complete velocity and clean boundaries until convergence at P3. --- ## Incidents & Debugging - [Laptop Memory Exhaustion Postmortem & Mitigation](../debug/2026-09-27-laptop-memory-exhaustion-postmortem.md): Mobile workstation UI lockup under memory pressure due to 0B swap causing synchronous file-backed page eviction; mitigated via compressed in-RAM swap (`zramSwap`) and proactive early OOM termination (`services.earlyoom`).