services:
  postgres:
    image: postgres:16-alpine
    container_name: seo-farm-postgres
    environment:
      POSTGRES_DB: seo_farm
      POSTGRES_USER: seo_farm
      POSTGRES_PASSWORD: seo_farm
    ports:
      - "5432:5432"
    volumes:
      - postgres-data:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U seo_farm -d seo_farm"]
      interval: 5s
      timeout: 3s
      retries: 10

  minio:
    image: minio/minio:latest
    container_name: seo-farm-minio
    command: server /data --console-address ":9001"
    environment:
      MINIO_ROOT_USER: seo_farm
      MINIO_ROOT_PASSWORD: seo_farm_secret
    ports:
      - "9000:9000"
      - "9001:9001"
    volumes:
      - minio-data:/data
    healthcheck:
      test: ["CMD", "mc", "ready", "local"]
      interval: 5s
      timeout: 3s
      retries: 10

volumes:
  postgres-data:
  minio-data:
