OperateGuide 09 / 12

Local development

Run the generated application, database, email, and checks.

01

Environment

  • DATABASE_URL connects the product to PostgreSQL.
  • APP_URL is the canonical application origin, normally http://localhost:3000 locally.
  • APP_ENV should be local for local development.
  • LOCAL_MAILBOX_DIR enables filesystem email delivery outside application source.
  • Provider keys may remain empty when their local adapters support it.
cp .env.example .env.local
02

Database

Migrate before starting account-enabled products. Use db:generate only while intentionally changing the schema; a clean generated product already includes its migrations.

docker compose up -d --wait db
pnpm db:migrate
pnpm db:studio
03

Application

The root dev command starts the Next.js web workspace. The default URL is http://localhost:3000.

pnpm install --frozen-lockfile
pnpm dev
04

Verification

Use targeted checks while editing and the complete verify command before merging. Playwright covers desktop and mobile user journeys in the reference fixtures.

pnpm typecheck
pnpm test
pnpm lint
pnpm build
pnpm test:e2e
pnpm verify