feat: support explicit source bundles through the common installer

This commit is contained in:
Codex
2026-10-06 18:31:23 +02:00
parent 785d96ea50
commit 5c05778614
11 changed files with 353 additions and 5 deletions
+29
View File
@@ -266,6 +266,35 @@ the lock; after a forcibly killed process, confirm that its owner is no longer r
before explicitly removing a stale lock. A different release requires the upgrade
path rather than this command.
## Advanced source build with the same prepared documents
Source compilation is an explicit choice before planning. It requires a ThothII
checkout containing the selected commit, Git, Node 24/npm, Go, Docker Buildx and
network access for dependencies. From `backend`, after `npm ci`:
```bash
node scripts/prepare-source-installation.mjs \
--revision COMMIT --version 0.1.0-source.1 \
--platform linux/amd64 --output /private/path/new-build
```
The command builds an isolated temporary worktree, excluding local edits and
untracked secrets. It does not publish images. The output directory must be new;
after failure preserve its private logs and retry in a new directory. Select
`--platform linux/arm64` explicitly when appropriate.
Use the resulting `bundle/bin/tht` and `bundle/release-manifest.json` in the same
`installation validate`, `plan` and `apply` steps above. The sealed plan records
`release.distribution: source`, revision, version and immutable local image IDs.
Use the Docker daemon containing those images and a Linux operator host matching
the bundle architecture; Windows runs the operator in WSL2.
`apply` pulls only PostgreSQL, Qdrant and Ollama and shares locks, journal,
migrations, binding import and readiness with prebuilt installation. A missing
local image or different source revision blocks planning, without automatic build
fallback. Changing revision or distribution requires a separate installation or
explicit upgrade. Source testing does not certify a public Docker Hub release.
## Manual source path: the two repositories
The remaining sections describe the existing manual path. Do not run its build/setup