Docs cleanup: current-state rewrite + three deployment modes + history/
- 10 era documents (phase plans, build summaries, redesign writeups, old runbooks, completed consolidation plan) moved to docs/history/ with a do-not-follow README. - Root README: current validated population ($2-20, 10-35% static gap + squeeze exception, SIP), Deployment section, automated-maintenance reality, corrected repo map (admin panel, youtube_claims, deploy/). - RUNBOOK rewritten for the running system: daily rhythm, health checks per deployment, and the production failure-mode table earned this week (env drift, pgdata mount traps, uid 10001, zombie approvals, PG_SKIP_ SCHEMA, timezone artifacts). - deploy/README.md is now the three-mode index: compose (canonical), systemd (local dev — unit templates now committed), helm (refresh staged as issue #8). Old k8s doc moved to deploy/helm/README.md. - docker/README.md: six TrueNAS gotchas, each from a real outage. - Admin panel improvements staged as GitHub issues #4-#7. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
1 parent
d4c695e213
commit
5ac2cc7b89
23 files changed
+680
-396
No files matched your search
@@ -0,0 +1,30 @@
|
||||
# Local deployment (systemd user services)
|
||||
|
||||
Unit templates for running the stack from a git checkout + venv (the original
|
||||
production shape; now the development shape). Paths inside the units assume
|
||||
`/mnt/c/code/momentum` + `/home/philip/.venvs/momentum` — adjust to your box.
|
||||
|
||||
```bash
|
||||
cp deploy/systemd/momentum-*.service ~/.config/systemd/user/
|
||||
systemctl --user daemon-reload
|
||||
systemctl --user enable --now momentum-loop momentum-dashboard momentum-qabot momentum-transcripts
|
||||
systemctl --user enable --now momentum-premarket-eval.timer # 20:00 ET weekdays
|
||||
loginctl enable-linger $USER # start on boot without login
|
||||
```
|
||||
|
||||
| Unit | What |
|
||||
|---|---|
|
||||
| momentum-loop | trading loop (`run_live_paper.py --no-dashboard`) |
|
||||
| momentum-dashboard | web dashboard :8765 (`dashboard_api.py`) |
|
||||
| momentum-qabot | Telegram Q&A bot (read-only) |
|
||||
| momentum-transcripts | YouTube → transcript → claims pipeline |
|
||||
| momentum-premarket-eval(.timer) | nightly SIP refetch + housekeeping + shadow-track re-validation |
|
||||
| momentum-testpg | local Postgres for test isolation (`/home/philip/pgrun` socket) — keep even when production is elsewhere |
|
||||
| momentum-controlroom | NiceGUI control room :8766 — **disabled by owner preference**; kept for reference |
|
||||
|
||||
Config comes from `.env` in the repo root (see `.env.example`). The same
|
||||
behavior-flag warnings as compose apply (`TRADING_AUTO_APPROVE=1` etc. — see
|
||||
`deploy/README.md`).
|
||||
|
||||
**Never run these enabled while the compose stack owns production** — two loops
|
||||
on one Alpaca account duplicate orders.
|
||||
Reference in new issue
Block a user