From 715b8c5f8cada78bac6dece53cc480f97b693d6a Mon Sep 17 00:00:00 2001 From: Thomas Joise Date: Thu, 16 Jul 2026 21:45:05 +0530 Subject: [PATCH] =?UTF-8?q?docs:=20correct=20HQ=20run=20instructions=20?= =?UTF-8?q?=E2=80=94=20launch=20server=20from=20repo=20root?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The DB path resolves to ./data/hq.db against the process working directory, so the server must run from the repo root; `cd apps/hq && npm start` would look in apps/hq/data and boot an empty database. Found while red-teaming the split by booting the server live against the real data/hq.db. Co-Authored-By: Claude Opus 4.8 (1M context) --- README.md | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 591f9c4..2cf9a5b 100644 --- a/README.md +++ b/README.md @@ -60,10 +60,14 @@ runbook (server, HTTPS, backups, Gmail/AWS/import wiring, the Postgres switch) i ```bash npm install # from the repo root (workspaces: packages/*, apps/*) -# Backend — HQ server (builds the server bundle, then runs it on :5182) -cd apps/hq && npm start -# First boot creates data/hq.db and prints a one-time owner password — capture it. -# Log in as admin@tecnostac.com with that password, then change it. +# Backend — HQ server. Build the bundle, then run it FROM THE REPO ROOT: the DB +# path resolves to ./data/hq.db against the current working directory, so the +# server must be launched from the repo root (not from apps/hq, which would look +# in apps/hq/data and boot an empty database). +npm run build --workspace @sims/hq +node apps/hq/dist/server.cjs # serves :5182 (API, built web UI, /share/:token) +# First boot on an empty data/ creates data/hq.db and prints a one-time owner +# password — capture it. Log in as admin@tecnostac.com, then change it. # Frontend — hq-web dev server (Vite on :5183, proxies /api and /share to :5182) cd apps/hq-web && npm run dev