Auctify is a modern online auction platform built with Next.js, allowing users to create, bid on, and manage auctions.
- User Authentication (Sign up, Log in)
- Create and manage auctions
- View active auctions
- Place bids on auctions
- User profiles
- Email notifications (e.g., for invoices)
- Automated processing of finished auctions
- Next.js
- React
- TypeScript
- Prisma (for database interaction)
- NextAuth.js (for authentication)
- Tailwind CSS (for styling)
- Resend (for emails)
Follow these steps to set up and run the project locally.
- Node.js (v18 or later)
- npm or yarn or pnpm or bun
- A database (e.g., PostgreSQL, MySQL) compatible with Prisma
- Environment variables configured (database URL, NextAuth secret, Resend API key, etc.)
- Clone the repository:
git clone [repository_url]
cd auctify- Install dependencies:
npm install
# or
yarn install
# or
pnpm install
# or
bun install- Set up your database and apply migrations:
npx prisma migrate dev --name initial_migration # Or the name of your first migration- Generate Prisma client:
npx prisma generatenpm run dev
# or
yarn dev
# or
pnpm dev
# or
bun devOpen http://localhost:3000 with your browser to see the result.
You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.
This project uses next/font to automatically optimize and load Geist, a new font family for Vercel.
This project includes Docker configuration for easy deployment and development.
- Docker and Docker Compose installed
- Environment variables configured
- Set up environment variables:
cp .env.example .envEdit .env with your actual values:
# Database credentials
usermysql=user
passwordmysql=password123
passwordmysqlroot=rootpassword123
# NextAuth secret (generate with: openssl rand -base64 32)
NEXTAUTH_SECRET=your-nextauth-secret-here
# Resend API key for emails
RESEND_API_KEY=your-resend-api-key-here- Build and run with Docker Compose:
docker-compose up --buildThis will:
- Build the Next.js application
- Start MySQL database
- Set up database with migrations
- Run the application on http://localhost:3000
- main_app: Next.js application (port 3000)
- db: MySQL 8 database (internal network only)
- auctify_net: Internal Docker network for service communication
The application uses these environment variables:
DATABASE_URL: MySQL connection stringNEXTAUTH_SECRET: Secret for NextAuth.js authenticationRESEND_API_KEY: API key for email sending
- Development: Use
npm run devfor local development with hot reload - Production: Docker setup uses
npm run buildandnpm startfor optimized production build
When running with Docker, the database is automatically created. To run migrations manually:
docker-compose exec main_app npx prisma migrate deploydocker-compose downTo remove database data:
docker-compose down -vTo learn more about Next.js, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
You can check out the Next.js GitHub repository - your feedback and contributions are welcome!
The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.
Check out our Next.js deployment documentation for more details.