Containerfile, compose and kustomize deploy with Litestream backup #9
Labels
No labels
bug
enhancement
epic
needs-info
needs-triage
ready-for-agent
ready-for-human
svd:fire
svd:go
svd:hold
svd:respec
svd:skip
wontfix
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
dev/people-mind-mcp#9
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent: #1. Records: ADR 0001.
What to build
Mailmind's deploy shape, one instance per person.
sync,apiandbackupcontainers on one volume; tokens and Source credentials mounted as files; mailmind reachable by service name for the evidence token path.backupcontainer.make image,make check,make modelandmake test-integrationtargets. CI files are added by the architect, not here.Acceptance criteria
compose upbrings/healthzand/healthz/syncgreen with a vCard Source fixture.kustomize buildof the example overlay validates and shows no secret material in the ConfigMap.peoplemind check.Blocked by
Filed under: operator word "go. compelling public-facing README.md as A0" sha256:3f9e946994fa
Rider from the #2 review (PR #11, merged
939e97c): the README's Quick start block is marked provisional throughout. This slice replaces it with the real compose, config example and connector URL, and drops every provisional marker. Also revisit the default_region default (AU in PR #12) when the config example is written.Architect note from the #7 gate (PR #23 merged as
41f602a): the image build in this slice callsscripts/fetch_model.py <dest>in its builder stage so the image carries the pinnedbge-small-en-v1.5int8 model (ADR 0006 §1, Amendment 1 item 5). The script is stdlib Python, hash-checks both files and exits 1 withmodel=error code=fetch-failedon any mismatch. The service never downloads a model at run time;[embed] model_dirmust point at the baked path. Schema is now v5.⏸ SVD architect gate: dev/peoplemind-mcp#9 containerfile-compose-and-kustomize-deploy-with-litestream-b
Status: CLEAN after 0 rework round(s) · 0 blocking defect(s) · 0 lens(es) INCONCLUSIVE (could not run) · 0 lens(es) DEGRADED (deterministic denial) · complexity
substrate· dispatch efforthighRun:
20261101T120531Z-a9a26490Held because: CLEAN but 11 open risk(s) (4 verification · 7 decision) — HOLD-ALL parks everything. The risks, verbatim:
Open risks:
syncwithout --once unless a carddav or mailmind Source exists. With only a vCard fixture, the production sync service would exit 2 and /healthz/sync would never go green. The lean's test overrides sync to --once with restart:no. Question: accept that test-only override, or open a follow-up issue so vCard-only sync loops (a src change outside this write set)? [decision]podman unshare chown -R 10001:10001 secrets; Docker: sudo chown). The README documents this and the integration fixture does it. Question: accept the documented chown, or run the services as the host uid (userns keep-id), which conflicts with the image-owned volume dirs? [decision]make imagesucceeds and its log shows model=ok, anduv run python3 -m pytest tests/test_deploy.py -k pins_every_image_by_digest -qpasses. [verification]make test-integrationreports all four integration tests in tests/test_deploy.py as passed, not skipped (-rs shows any skip). The architect runs this before merge. [verification]uv run python3 -m pytest -q --basetemp "$(mktemp -d "${TMPDIR:-/var/tmp}/svd.XXXXXX")/x"before the first edit. After the change,make checkmust show the same failure set plus the new static tests/test_deploy.py passes, with ruff and strict mypy clean. [verification]replicatestarting before peoplemind.db exists, and the binary at /usr/local/bin/litestream in the upstream image. Check at dispatch against the pinned version's docs or image. test_litestream_restore_passes_check must pass on the host. If replicate exits on a missing DB, add backup depends_on sync (service_started) inside the existing files. [verification]Change: Mailmind's deploy files could not be read: the sandbox denied imap-mailmind-mcp (Open Risk 1). The lean therefore mirrors patterns inside this repo: container-engine selection from scripts/radicale.sh:3, the host-only marker plus skipif from tests/test_carddav_radicale.py:18-21, and the check output from cli.py:33-41.
Files:
Containerfile·.dockerignore·compose.yaml·compose.mailmind.yaml·deploy/config.example.toml·deploy/litestream.yml·deploy/kustomize/base/kustomization.yaml·deploy/kustomize/base/deployment.yaml·deploy/kustomize/base/service.yaml·deploy/kustomize/base/pvc.yaml·deploy/kustomize/overlays/example/kustomization.yaml·deploy/kustomize/overlays/example/config.toml·tests/test_deploy.py·Makefile·pyproject.toml·README.mdDerived artifacts:
uv.lock·models/bge-small-en-v1.5/*(unattested — exists claim failed)Decision: accept the 11 open risk(s) above and dispatch this spec (
svd:go), or park (svd:skip) / re-spec (svd:respec)?Your call (when this issue is held at the gate via
svd:hold):svd:go— approve; Half-B dispatch accepts exactly this spec (open risks accepted)svd:firebesidesvd:go— approve AND authorise the Half-B fire from the phone; never on its ownsvd:skip— park it; dispatch refuses it and the issue stays for a humansvd:respec— discard this spec; the next Half-A run re-produces it with this record as prior-attempt contextSpec:
/Users/piers/.local/state/exhaust/groupthink/specs/2026-11-01-containerfile-compose-and-kustomize-deploy-with-litestream-b.md— next:codex-svd dispatch --args '<same-json>' --approved-spec-path /Users/piers/.local/state/exhaust/groupthink/specs/2026-11-01-containerfile-compose-and-kustomize-deploy-with-litestream-b.mdArchitect gate on the Half-A spec (run 20261101T120531Z-a9a26490, verdict CLEAN, 16 files, class substrate, dispatch base main
0d8ea14). The sandbox could not read mailmind, so the rulings paste its deploy shape. Recorded in the spec's## Agent Adjustments:uv==0.12.17exporting requirements, builder with pip andscripts/fetch_model.py, runtime),python:3.12-slim-bookwormpinned per architecture with mailmind's two digests, uid and gid 1000, non-root, no network resolution by dispatch.imageandimage-amd64targets and acheckthat honoursPYTEST_ADDOPTS.PEOPLEMIND_UID/PEOPLEMIND_GID(no chown step),backupis the upstreamlitestream/litestream:0.3.13image with S3 credentials as environment, as mailmind's is.deploy/litestream.example.ymlin mailmind's explicit form (file replica default, S3 commented), mounted from config, not baked; no env expansion orurl:dependence.prepareinit container copies config and secrets to mode 0600 per role (apigets the read token only,syncthe salt and credentials,LITESTREAM_*reachbackuponly); restricted pod security as mailmind.deploy/k8s/baseanddeploy/k8s/overlays/example, with a placeholdersecret-peoplemind.example.yamlin the overlay.compose.mailmind.yaml: both projects name their MCP serviceapi, so the README documents-p mailmind, a network block,http://mailmind:8420/mcp, and the architect adds amailmindalias on mailmind's side. Kubernetes URL ismailmind-api…:8420, not 8080. Live check stays at #10.--onceaccepted (max_lag_secondsdefault 86400 keeps/healthz/syncgreen); production vCard-only sync filed as #25.AUcode default kept; example configs set the region explicitly.make image,make test-integrationandkustomize buildon a scratch worktree before merge; dispatch runs no container tooling.Awaiting the operator's
svd:go.spec-verify-dispatch Half B for dev/peoplemind-mcp#9 containerfile-compose-and-kustomize-deploy-with-litestream-b completed integration verify.
97515596e99751559(Forgejo commit statuses empty). Local: make check passes (252 passed, 5 skipped, 4 integration deselected). Host integration run is pending with the architect.9751559, so no remote check exists to read.make test-integrationon a host with podman or Docker plus kustomize before merge.codex-svd ship --run-id 20261101T202634Z-145ae343 --confirm-merge)