version: '3.9' services: django-backend: build: context: ./backend # Path to the backend Dockerfile container_name: django-backend ports: - "8000:8000" # Map backend port volumes: - ./backend:/app # Mount backend code for development environment: - DEBUG=1 - DJANGO_ALLOWED_HOSTS=localhost # Add your frontend URL later - DATABASE_URL=sqlite:///db.sqlite3 depends_on: - redis react-frontend: build: context: ./backend/frontend # Path to the frontend Dockerfile container_name: react-frontend ports: - "3000:3000" # Map frontend port volumes: - ./backend/frontend:/app # Mount frontend code for development stdin_open: true tty: true redis: image: redis:6 container_name: redis ports: - "6379:6379" # Redis port for Channels