Files
upstream-mirror aa862d2a17
Some checks failed
Checks / Tests & checks (push) Has been cancelled
Checks / Build all projects (push) Has been cancelled
Deploy .com / Deploy dotcom to ${{ (github.ref == 'refs/heads/production' && 'production') || (github.ref == 'refs/heads/main' && 'staging') || 'preview' }} (push) Has been cancelled
Deploy templates / Deploy templates (push) Has been cancelled
End to end tests (examples) / End to end tests (examples) (push) Has been cancelled
End to end tests (perf) / End to end tests (perf) (push) Has been cancelled
Publish SDK packages / Publish SDK packages (push) Has been cancelled
End to end tests (dotcom) / End to end tests (dotcom) (push) Has been cancelled
End to end tests (mermaid readability) / End to end tests (mermaid readability) (push) Has been cancelled
Publish SDK packages / Tell user released version (push) Has been cancelled
Publish SDK packages / Publishes code templates to separate repositories (push) Has been cancelled
Publish SDK packages / Deploys the template demos with the new SDK version (push) Has been cancelled
Deploy grafana resources / ${{ github.event_name == 'push' && 'Deploy grafana resources' || 'Validate grafana resources (dry run)' }} (push) Failing after 0s
i18n upload strings / Upload latest strings (push) Failing after 0s
Deploy analytics worker / Deploy analytics worker to ${{ (github.ref == 'refs/heads/production' && 'production') || (github.ref == 'refs/heads/main' && 'staging') || 'preview' }} (push) Failing after 0s
Deploy bemo / Deploy bemo to ${{ (github.ref == 'refs/heads/bemo-production' && 'production') || (github.ref == 'refs/heads/main' && 'staging') || 'preview' }} (push) Failing after 0s
End to end tests (dotcom) / Check for relevant changes (push) Failing after 0s
End to end tests (examples) / Check for relevant changes (push) Failing after 0s
End to end tests (mermaid readability) / Check for relevant changes (push) Failing after 0s
End to end tests (perf) / Check for relevant changes (push) Failing after 0s
Publish editor extensions / Publish editor extensions (push) Failing after 0s
Publish SDK packages / Remove the publish-packages label (push) Has been skipped
Close inactive issues / close-issues (push) Failing after 3s
i18n download strings / Download latest strings (push) Failing after 0s
Post release marketing summary to Discord / Post release marketing summary to Discord (push) Failing after 0s
Post release crew to Discord / Post release crew to Discord (push) Failing after 0s
Prune preview deploys / Prune preview deploys (push) Failing after 1s
Staging E2E Daily Cleanup / Daily Cleanup of Test Files (push) Failing after 1s
top-up: 8 source files 128-600 KB
2026-09-23 16:16:53 +05:00
..

dotcom

Development

You'll need a clerk publishable and secret key.

In sync-worker/.dev.vars, set CLERK_PUBLISHABLE_KEY & CLERK_SECRET_KEY. In client/.env.local, set VITE_CLERK_PUBLISHABLE_KEY.

The dev stack is orchestrated by process-compose. You don't need to install it — yarn dev-app fetches the pinned binary on first use. Run the app from the repo root:

yarn dev-app

This brings up the whole stack — postgres and pgbouncer (in containers), zero-cache, the workers, and the client — as host processes. The ports are fixed, so only one dotcom dev stack can run at a time. The services and their startup order are defined in process-compose.yaml.

Working with the stack

By default yarn dev-app opens the process-compose TUI, listing each service with its status, logs, and health.

  • Quit: F10 or Ctrl-C. This stops every process and runs postgres's docker compose down — the clean way to stop. Closing the terminal tab instead can leave the postgres container and stray workers running.

  • Inspect a service: select it with the arrow keys to see its logs; press F1 for the full key bindings (start / stop / restart a selected process).

  • Plain interleaved logs, no TUI: PC_DISABLE_TUI=1 yarn dev-app streams every service's logs to stdout (this is also how it runs in CI).

  • Drive it from another terminal or a script — the process-compose client connects to the running stack:

    yarn dev-app:doctor                                       # status of every service
    yarn exec process-compose process logs zero-cache --tail 200
    yarn exec process-compose process restart sync-worker
    
  • Reset server state: yarn dev-app:clean tears down the postgres container + volume, the zero replica, and wrangler state.

Browser-side state is separate. After starting the stack, visit http://localhost:3000/dev/reset-local-state to clear local storage, IndexedDB, caches, service workers, accessible cookies, and Clerk session state for the current origin.