services: bambuddy: image: ghcr.io/maziggy/bambuddy:latest container_name: bambuddy # network_mode: host # Recommended for automatic printer discovery volumes: - ${DATA_PATH}:/app/data - ${LOGS_PATH}:/app/logs environment: - PUID=${PUID:-1000} - PGID=${PGID:-1000} - TZ=America/Toronto # Your timezone - TRUSTED_FRAME_ORIGINS=http://homeassistant.local:8123 ports: - "${PORT:-8870}:8000" # Web UI - "3000:3000" # Virtual printer bind/detect - "3002:3002" # Virtual printer bind/detect (alt port) - "990:990" # Virtual printer FTPS - "8883:8883" # Virtual printer MQTT - "6000:6000" # Virtual printer file transfer tunnel - "322:322" # Virtual printer RTSP camera (X1/H2/P2) - "2024-2026:2024-2026" # Virtual printer proprietary ports (A1/P1S) - "50000-50029:50000-50029" # Virtual printer FTP passive data — 3 VPs × 10-port slice restart: unless-stopped # Docker SIGKILLs after 10s by default. Bambuddy stops well inside that, # but the headroom means a slow teardown (several virtual printers on a Pi) # can still checkpoint the database instead of being killed mid-write. stop_grace_period: 30s cap_add: - NET_BIND_SERVICE volumes: bambuddy_logs: