Monorepo Layout
pnpm workspaces, Turbo build orchestration, the five apps, the six shared packages, and Turbo-leaf isolation rules.
Sixième Étoile is structured as a monorepo managed with pnpm workspaces and orchestrated by Turbo.
Repository structure
sixieme-etoile/
├── apps/
│ ├── web/ # Next.js 16 — Operator back-office (port 3000)
│ ├── agency/ # Next.js 16 — Agency portal (port 3001)
│ ├── tracking/ # Next.js 16 — Customer tracking (port 3002)
│ ├── docs/ # Next.js 16 + FumaDocs — Documentation platform (port 3003)
│ └── driver/ # Vite PWA — Chauffeur app (port 8080)
├── packages/
│ ├── database/ # Prisma multi-file schema + migrations
│ ├── api/ # Hono REST + SSE API server
│ ├── auth/ # Better Auth — session management
│ ├── realtime/ # EventBus + SSE streams
│ ├── ui/ # Shared component library (shadcn/ui)
│ └── i18n/ # next-intl JSON translation catalogues
├── turbo.json # Build pipeline configuration
└── pnpm-workspace.yamlTurbo build pipeline
Turbo orchestrates builds across the workspace. Each package declares its build dependencies — for example, apps/web depends on packages/api#build, which in turn depends on packages/database#build.
Key commands:
pnpm --filter docs dev # Start the docs site on port 3003
pnpm --filter docs build # Build the static export (produces out/)
pnpm --filter web dev # Start the operator back-office on port 3000
pnpm build # Build all packages and apps in dependency orderThe five apps
| App | Framework | Port | Purpose |
|---|---|---|---|
apps/web | Next.js 16 | 3000 | Operator back-office — quotes, orders, invoicing, dispatch |
apps/agency | Next.js 16 | 3001 | Agency portal — booking wizard, quote requests, mini-CRM |
apps/tracking | Next.js 16 | 3002 | Customer tracking — live mission status |
apps/docs | Next.js 16 + FumaDocs | 3003 | Documentation platform (static export) |
apps/driver | Vite PWA | 8080 | Chauffeur app — mission management, live location |
See Apps overview for details on each app.
The six shared packages
| Package | Purpose |
|---|---|
packages/database | Prisma multi-file schema, migrations, generated client |
packages/api | Hono 4 REST + SSE API server with hono-openapi |
packages/auth | Better Auth sessions, organization membership, role policies |
packages/realtime | EventBus abstraction + SSE stream management |
packages/ui | Shared design system — shadcn/ui components, Tailwind tokens |
packages/i18n | next-intl JSON catalogues for apps/web, apps/agency, apps/tracking |
See Packages overview for details on each package.
Turbo-leaf isolation rule
apps/docs is declared as a Turbo leaf — its build task has no dependency edges to packages/database, packages/api, packages/auth, packages/realtime, or the four business apps.
This means:
- The documentation build never triggers a business-logic build.
apps/docsdoes not importpackages/database,packages/api,packages/auth, orpackages/realtimeat build time.- Architecture pages in
apps/docsdescribe these packages as authored text; they do not execute their code.
Consequence: changing the business apps does not invalidate the docs build cache, and vice versa. Builds remain independent.
See also: Data Model · Pricing Engine · API Reference