Database (Drizzle)
Centralized Drizzle ORM schemas, pooled database clients, and migration tooling.
Database Package (`@repo/db`)
Morax centralizes database models and connections into packages/db powered by Drizzle ORM. This allows both your server backend and Next.js server actions to share the exact same database schema and types.
Schema Definitions
Schemas are defined with full TypeScript inference:
packages/db/src/schema/users.ts
Pooled Database Client
A singleton connection client is exported from the package index:
packages/db/src/index.ts
Migrations & Drizzle Studio
Run migrations or launch the visual database GUI directly from the root workspace:
Database Commands
Multi-App Access
Both apps/server and apps/web can query the database with zero duplication of models:
Unified Query