This runbook gives you one reliable path to boot the stack and verify GraphQL flows end to end.
nvm use
# or: asdf shell nodejs 20.19.6
yarn installNode version targets:
.nvmrc:20.19.6.node-version:20
Start PostgreSQL + Elasticsearch first:
docker compose up -d postgres elasticsearchCheck health:
docker compose psBoth services should be healthy before launching the app.
Set these variables in your shell (or .env) before starting the app.
export NODE_ENV=development
export PORT=5000
export DATABASE_URL='postgresql://advisors:advisors@localhost:55432/advisors?schema=public'
export DISABLE_AUTOMATION=true
export AUTH_SECRET='local-dev-secret'
export AUTH_AUDIENCE='event-test-2025'
export UPLOADER_BASE='http://localhost:3000'
export UPLOADER_SECRET='local-dev-secret'
export GOTENBERG_BASE='http://localhost:3001'
export EMAIL_HOST='localhost'
export EMAIL_PORT='1025'
export EMAIL_USER='local'
export EMAIL_PASS='local'
export EMAIL_FROM='local@example.com'
export TWILIO_ACCOUNT_SID='AC00000000000000000000000000000000'
export TWILIO_AUTH_TOKEN='local-dev-secret'
export TWILIO_PHONE='+15555555555'Notes:
AUTH_SECRETandAUTH_AUDIENCEmust match what your local token/test scripts use.DATABASE_URLshould uselocalhost:55432when running the app outside Docker.
yarn build
yarn devGraphQL endpoint:
http://localhost:5000/graphql
In another terminal:
yarn seed-dummyThis creates deterministic local test records, including:
- advisor id
advisor-alice-test - advisor id
advisor-bob-test - request id
request-test-2025
With the app running, execute:
yarn test-localThis runs:
yarn seed-dummy- Public GraphQL query
- Admin-auth query (
submittedRequests) - Advisor-auth query (
getRequest) - Advisor mutation (
respondRequest) - Verification query (
getRequestAssignment)
If all pass, your local backend path is working end to end.
-
Prismaconnection errors:- Confirm Postgres is healthy:
docker compose ps - Re-check
DATABASE_URLhost/port (localhost:55432outside Docker)
- Confirm Postgres is healthy:
-
Auth errors (
Unauthorized, audience/secret issues):- Re-check
AUTH_SECRET - Re-check
AUTH_AUDIENCE
- Re-check
-
GraphQL upload typing/build issues:
- Re-run
yarn install - Re-run
yarn build
- Re-run
-
Seed/test query failures:
- Ensure app is running on port
5000 - Re-run
yarn seed-dummy
- Ensure app is running on port