Installation

Get MatchNest running on your local machine or production server.

Requirements

  • Node.js 18.17+ (20+ recommended)
  • npm 9+ or pnpm / yarn
  • Git
  • Linux/macOS recommended for production (Windows supported for dev)

Step 1 — Clone the Repository

git clone https://github.com/your-repo/matchnest.git
cd matchnest

Step 2 — Install Dependencies

npm install

This also runs prisma generate automatically via the postinstall script.

Step 3 — Configure Environment Variables

cp .env.example .env

Open .env and configure the following required variables:

# Database
DATABASE_URL="file:./dev.db"          # SQLite (default)
# DATABASE_URL="postgresql://..."     # PostgreSQL (production)

# Authentication
JWT_SECRET="your-very-long-random-secret-key"
NEXTAUTH_URL="http://localhost:3000"

# File Uploads
UPLOAD_MAX_SIZE_MB=10                 # Max file size in MB

# Optional: Email (for password reset)
SMTP_HOST="smtp.gmail.com"
SMTP_PORT=587
SMTP_USER="[email protected]"
SMTP_PASS="your-app-password"
SMTP_FROM="MatchNest <[email protected]>"

Step 4 — Set Up the Database

# Push the schema to the database
npm run db:push

# Seed with demo data (optional but recommended)
npm run db:seed

The seed creates:

Step 5 — Start the Development Server

npm run dev

Open http://localhost:3000. The app should be live.

Available Scripts

ScriptDescription
npm run devStart development server with hot reload
npm run buildBuild for production
npm startStart production server
npm run db:pushPush Prisma schema to database
npm run db:seedSeed database with demo data
npm run db:resetReset and re-seed database
npm run db:studioOpen Prisma Studio GUI
npm run generateRegenerate Prisma client