You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
git clone https://github.com/icekidtech/devtrivia.git
cd devtrivia
cd backend && pnpm install
cd ../frontend && ppnpm install
2. Set Up Database
Install PostgreSQL and create a database named devtrivia.
Update backend/.env:
DATABASE_URL="postgresql://user:password@localhost:5432/devtrivia?schema=public"JWT_SECRET="your-jwt-secret-here"OPENAI_API_KEY="sk-your-openai-key"# Optional for AI questions
Run migrations:
cd backend
npx prisma migrate dev --name init
npx prisma studio # Optional: GUI to view DB
3. Run Servers
Backend:
cd backend
pnpm run start:dev # http://localhost:3000
Frontend:
cd ../frontend
pnpm run dev # http://localhost:3001
DATABASE_URL="postgresql://user:password@localhost:5432/devtrivia?schema=public"JWT_SECRET="change-this-to-a-random-string"OPENAI_API_KEY="sk-..."# Only if using AI