services:
  wedding-web:
    image: nginx:alpine
    container_name: wedding-web
    restart: unless-stopped
    ports:
      - "127.0.0.1:8080:80"
    volumes:
      - ./frontend/nginx/default.conf:/etc/nginx/conf.d/default.conf:ro
    depends_on:
      - backend

  backend:
    build: ./backend
    container_name: wedding-backend
    restart: unless-stopped
    ports:
      - "127.0.0.1:5000:8000"
    volumes:
      - ./data/uploads:/app/uploads
      - ./data/db:/app/db
    environment:
      - DB_PATH=/app/db/app.sqlite3
      - UPLOAD_FOLDER=/app/uploads
      - EVENT_PASSWORD=${EVENT_PASSWORD:-wedding2026}
      - HOST_PASSWORD=${HOST_PASSWORD:-gastgeber2026}
      - WEDDING_DATE=${WEDDING_DATE:-}
      - SECRET_KEY=${SECRET_KEY:-change-me-in-production}
      - MAX_UPLOAD_BYTES=${MAX_UPLOAD_BYTES:-268435456}
