version: '3.8'

services:
  # Development service
  app-dev:
    build:
      context: .
      dockerfile: Dockerfile
    ports:
      - "3000:3000"
    volumes:
      - .:/app
      - /app/node_modules
      - /app/.next
    environment:
      - NODE_ENV=development
    command: npm run dev
    profiles:
      - dev

  # Production service
  app-prod:
    build:
      context: .
      dockerfile: Dockerfile
    ports:
      - "3000:3000"
    environment:
      - NODE_ENV=production
      - SITE_URL=${SITE_URL:-https://hamtonbrown.com}
      - CONTACT_TO_EMAIL=${CONTACT_TO_EMAIL:-contact@hamtonbrown.com}
      - RESEND_API_KEY=${RESEND_API_KEY}
    restart: unless-stopped
    profiles:
      - prod

networks:
  default:
    name: hamtonbrown-network
