name: bytebot services: bytebot-desktop: # Build from source with OpenCV 4.8.0 build: context: .. dockerfile: packages/bytebotd/Dockerfile shm_size: "2g" container_name: bytebot-desktop restart: unless-stopped hostname: computer privileged: true ports: - "9990:9990" # bytebotd service & noVNC - "8081:8081" # progress websocket environment: - DISPLAY=:0 - BYTEBOT_GRID_OVERLAY=true - BYTEBOT_GRID_DEBUG=false - BYTEBOT_PROGRESSIVE_ZOOM_USE_AI=true - BYTEBOT_UNIVERSAL_TEACHING=${BYTEBOT_UNIVERSAL_TEACHING:-true} - BYTEBOT_ADAPTIVE_CALIBRATION=${BYTEBOT_ADAPTIVE_CALIBRATION:-true} - BYTEBOT_ZOOM_REFINEMENT=${BYTEBOT_ZOOM_REFINEMENT:-true} - BYTEBOT_COORDINATE_METRICS=${BYTEBOT_COORDINATE_METRICS:-true} - BYTEBOT_POST_CLICK_CALIBRATION=true - BYTEBOT_DRIFT_COMPENSATION=true - BYTEBOT_DRIFT_SMOOTHING=0.2 # Accuracy aids - BYTEBOT_PRECLICK_SNAP=true - BYTEBOT_SNAP_RADIUS=6 - BYTEBOT_SNAP_PENALTY=0.25 - BYTEBOT_CLICK_RETRY_ON_NOCHANGE=true - BYTEBOT_CLICK_VERIFY_DELAY=250 - BYTEBOT_CLICK_VERIFY_RADIUS=12 - BYTEBOT_CLICK_VERIFY_THRESHOLD=4.0 - BYTEBOT_CLICK_RETRY_MAX=1 # Holo 1.5-7B integration - BYTEBOT_CV_USE_HOLO=${BYTEBOT_CV_USE_HOLO:-true} - HOLO_URL=${HOLO_URL:-http://bytebot-holo:9989} - HOLO_TIMEOUT=${HOLO_TIMEOUT:-30000} depends_on: bytebot-holo: condition: service_healthy networks: - bytebot-network postgres: image: ${BYTEBOT_POSTGRES_IMAGE:-public.ecr.aws/docker/library/postgres:16-alpine} container_name: bytebot-postgres restart: unless-stopped ports: - "5432:5432" environment: - POSTGRES_PASSWORD=postgres - POSTGRES_USER=postgres - POSTGRES_DB=bytebotdb networks: - bytebot-network volumes: - postgres_data:/var/lib/postgresql/data bytebot-agent: build: context: .. dockerfile: packages/bytebot-agent/Dockerfile container_name: bytebot-agent restart: unless-stopped ports: - "9991:9991" environment: - DATABASE_URL=${DATABASE_URL:-postgresql://postgres:postgres@postgres:5432/bytebotdb} - BYTEBOT_DESKTOP_BASE_URL=${BYTEBOT_DESKTOP_BASE_URL:-http://bytebot-desktop:9990} - BYTEBOT_LLM_PROXY_URL=${BYTEBOT_LLM_PROXY_URL:-http://bytebot-llm-proxy:4000} - ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY} - OPENAI_API_KEY=${OPENAI_API_KEY} - GEMINI_API_KEY=${GEMINI_API_KEY} - OPENROUTER_API_KEY=${OPENROUTER_API_KEY} - BYTEBOT_ZOOM_REFINEMENT=${BYTEBOT_ZOOM_REFINEMENT:-true} - BYTEBOT_GRID_OVERLAY=true - BYTEBOT_PROGRESSIVE_ZOOM_USE_AI=true # Agent-side verification + screenshot policy - BYTEBOT_CLICK_VERIFY=true - BYTEBOT_POST_ACTION_SCREENSHOT=true - BYTEBOT_INCLUDE_FULL_AFTER_VERIFY=true # Holo 1.5-7B integration - BYTEBOT_CV_USE_HOLO=${BYTEBOT_CV_USE_HOLO:-true} - HOLO_URL=${HOLO_URL:-http://bytebot-holo:9989} - HOLO_TIMEOUT=${HOLO_TIMEOUT:-30000} depends_on: postgres: condition: service_started bytebot-holo: condition: service_healthy networks: - bytebot-network bytebot-ui: build: context: .. dockerfile: packages/bytebot-ui/Dockerfile args: - BYTEBOT_AGENT_BASE_URL=${BYTEBOT_AGENT_BASE_URL:-http://bytebot-agent:9991} - BYTEBOT_DESKTOP_VNC_URL=${BYTEBOT_DESKTOP_VNC_URL:-http://bytebot-desktop:9990/websockify} # Use pre-built image image: ghcr.io/bytebot-ai/bytebot-ui:edge container_name: bytebot-ui restart: unless-stopped ports: - "9992:9992" environment: - NODE_ENV=production - BYTEBOT_AGENT_BASE_URL=${BYTEBOT_AGENT_BASE_URL:-http://bytebot-agent:9991} - BYTEBOT_DESKTOP_VNC_URL=${BYTEBOT_DESKTOP_VNC_URL:-http://bytebot-desktop:9990/websockify} - NEXT_PUBLIC_PROGRESS_WS_PORT=${NEXT_PUBLIC_PROGRESS_WS_PORT:-8081} depends_on: - bytebot-agent networks: - bytebot-network bytebot-holo: build: context: ../packages/bytebot-holo dockerfile: Dockerfile container_name: bytebot-holo restart: unless-stopped ports: - "9989:9989" runtime: nvidia deploy: resources: reservations: devices: - driver: nvidia count: all capabilities: [gpu, compute, utility] environment: - HOLO_HOST=0.0.0.0 - HOLO_PORT=9989 # Device auto-detection: 'auto' detects cuda/cpu in container # On Apple Silicon: Docker uses CPU (MPS not available in containers) # On NVIDIA: Docker uses CUDA if nvidia-docker runtime available # Override with: cpu, cuda - HOLO_DEVICE=${HOLO_DEVICE:-auto} - HOLO_MIN_CONFIDENCE=${HOLO_MIN_CONFIDENCE:-0.3} - HOLO_MODEL_DTYPE=${HOLO_MODEL_DTYPE:-float16} - NVIDIA_VISIBLE_DEVICES=all - NVIDIA_DRIVER_CAPABILITIES=compute,utility - NVIDIA_REQUIRE_CUDA= volumes: # Optional: mount weights to persist across rebuilds - holo_weights:/app/weights networks: - bytebot-network # GPU support configured in docker-compose.override.yml (automatically loaded) # Requires: nvidia-container-toolkit installed on host # Apple Silicon: MPS not available in Docker, runs on CPU (for GPU use native setup) healthcheck: test: ["CMD", "curl", "-f", "http://localhost:9989/health"] interval: 30s timeout: 10s retries: 3 start_period: 60s networks: bytebot-network: driver: bridge volumes: postgres_data: holo_weights: