Deployment
Constellation is deployed on Vercel as a multi-zone topology:
| Zone | Host | Vercel project |
|---|---|---|
| Directory (root) | constellation.planetb2b.com | constellation-directory |
| Project Tracker | /projects/* (rewritten) | constellation-platform |
| Catalog | /catalog/* (rewritten) | constellation-catalog |
| Docs (planned) | docs.planetb2b.com | constellation-docs (INF-18) |
Directory is the root zone and rewrites requests for /projects/* and /catalog/* to the other Vercel projects.
NEXT_PUBLIC_BASE_PATH
Sub-zone apps read this env var at build time:
| Environment | Value | Behaviour |
|---|---|---|
| Production | /projects or /catalog | Multi-zone: served under prefix, rewrites from Directory |
| Preview | unset | Standalone: served at / for preview deploys |
| Local dev | unset | Standalone: turbo dev on app-local port |
fetch() and basePath
Next.js auto-prepends basePath to <Link> and router.push, but not to fetch(). Use the apiUrl() helper from each app's src/lib/api-url.ts:
import { apiUrl } from '@/lib/api-url';
const res = await fetch(apiUrl('/api/people')); // '/projects/api/people' in prod
Stub — migration gate, environment variables, and Vercel project wiring to be added.