feat: add grind-stack verify lifecycle for package work [#632]
Serial one-at-a-time test harness: builds under ukrrs-batch.slice, ephemeral pg/redis/mysql per manifest addons, app driven by the real CLOUDRON_* env contract. All resources labeled cloudron.grind=1 so down/sweep cannot touch fleet containers. AGENTS.md documents the per-package lifecycle (up/curl/logs/down/sweep) + host resource rules.
This commit is contained in:
@@ -136,10 +136,28 @@ auth app.
|
||||
**Standard package steps:**
|
||||
1. `mkdir -p Package-Workspace/<Category>/<app>/` and clone upstream into `repo/`.
|
||||
2. Write `Dockerfile` + `CloudronManifest.json` (+ `start.sh` if runtime setup needed).
|
||||
3. `docker build` to validate locally.
|
||||
3. Verify with the grind lifecycle (below): `scripts/grind-stack.sh up <pkg-dir>`
|
||||
→ `curl` / `logs` → `down`.
|
||||
4. Write `README.md` + `CHANGELOG.md` + `logo.png` (+ `.env.example`).
|
||||
5. Commit as `feat: add <app> Cloudron package (<Category>)`, push.
|
||||
6. Run the gardening protocol above (update STATUS / README / JOURNAL).
|
||||
7. `scripts/grind-stack.sh sweep <pkg-dir>` — drop the test image + dangling
|
||||
build cache so disk usage stays flat across the grind.
|
||||
|
||||
**Grind lifecycle** ([`scripts/grind-stack.sh`](scripts/grind-stack.sh)): serial
|
||||
verify-stack harness. `up` builds the image under `ukrrs-batch.slice` and starts
|
||||
ephemeral postgres/redis/mysql matching the manifest's addons, plus the app
|
||||
container driven by the real `CLOUDRON_*` env contract — every resource labeled
|
||||
`cloudron.grind=1`, so `down`/`sweep` can never touch fleet containers. One
|
||||
stack at a time (serial lock; `up` refuses while one is live).
|
||||
|
||||
**Host resource rules (day/night, disk):** all builds + test stacks run under
|
||||
`ukrrs-batch.slice` (cores 0-5, CPUWeight 25 — cores 6-7 stay interactive).
|
||||
Night window 22:00-07:00 Central tolerates wider build parallelism; avoid
|
||||
LLM-heavy sub-agent fan-outs 01:00-05:00 (z.ai peak ladder). Docker storage
|
||||
lives on `/data2` (SSD; moved off the NVMe root 2026-09-06 via ultix
|
||||
`15-docker-to-data2.sh` — rollback: delete the docker.service.d data-root
|
||||
drop-in, daemon-reload, restart).
|
||||
|
||||
**Recurring gotchas (from JOURNAL.md):**
|
||||
- `chmod` in `RUN` fails on Cloudron base → make scripts executable on the host.
|
||||
|
||||
Reference in New Issue
Block a user