Deployment & operations
Full description: Read the full narrative
Deployment stack
| Service | Image | Port | Role |
|---|---|---|---|
| terranoetis | multi-stage Dockerfile (node:20-alpine) | 3001 | Express API + built SPA served same-origin in production |
| redis | redis:7-alpine | 6379 | cache + memory hot path; optional — SQLite fallback |
| causal-service | Python microservice (DoWhy + Flask) | 5001 | causal discovery (/discover, /health) |
Volumes and mounts (terranoetis-data, redis-data, read-only .env) and full commands: DEPLOYMENT.md · docker-compose.yml · Dockerfile.
Configuration contract
| Variable | Behaviour |
|---|---|
JWT_SECRET / ADMIN_BOOTSTRAP_PASSWORD | production hard-requirement ≥ 32 / ≥ 16 chars; boot refuses otherwise |
PROXY_PORT / PORT | 3001 default chain; measured boot served on a chosen port with health “version: 3.1” |
103 variables in .env.example (62 named *KEY/*TOKEN/*SECRET) | missing key ⇒ that feature disables; the 3 local sims + analytical engine unaffected |
~/.kaggle/kaggle.json + KAGGLE_BIN, poll/settle/grace vars | transport for the 4 routed kernels; credentials read only from ~/.kaggle — never from the repo |
LOCAL_SIM_TIMEOUT_MS | local kernel spawn timeout, default 120,000 ms server/kaggle/simRunner.ts:136 |
TIMESCALE_CONNECTION_STRING / CLICKHOUSE_HOST / KAFKA_BROKERS | optional H3 spatial backends; graceful no-op when unset |
CI pipeline
ci.yml runs 10 jobs (typecheck, lint, unit, integration, build, Playwright, Docker build, coverage, audit, summary). docs.yml adds the documentation gate: build-drift check + quality-gate on pushes/PRs to main/develop touching docs/site/**, scripts/docs/**, or the root markdown files. deploy-docs.yml publishes docs/site/ to GitHub Pages via upload-pages-artifact (workflow deploy; also manually dispatchable), with .nojekyll so every file is delivered byte-exact.
Optional Kaggle setup (for the 4 routed kernels)
Create a token at kaggle.com/settings/account → save as ~/.kaggle/kaggle.json (chmod 600) → install the CLI (pip install kaggle) or set KAGGLE_BIN. Without it, the routed kernels disable gracefully; earthquake/wildfire/hurricane simulations, all 150 analytical tools, monitoring and the API work with no token at all. Transport details and honesty labels: execution modes.