version: '3.8'

services:
  # Services supplémentaires pour le développement
  jupyter:
    image: jupyter/pyspark-notebook:latest
    container_name: jupyter
    depends_on:
      - spark-master
    environment:
      SPARK_OPTS: "--master=spark://spark-master:7077 --driver-memory=1G --executor-memory=1G"
    volumes:
      - ./notebooks:/home/jovyan/work
      - ./src:/home/jovyan/src
      - ./data:/home/jovyan/data
    ports:
      - "8888:8888"
    networks:
      - data_pipeline_network

  # Augmenter les ressources pour le développement
  spark-worker:
    environment:
      SPARK_WORKER_MEMORY: 2G
      SPARK_WORKER_CORES: 2

  # Outils de développement supplémentaires
  adminer:
    image: adminer:latest
    container_name: adminer
    depends_on:
      - postgres
    ports:
      - "8084:8080"
    networks:
      - data_pipeline_network
