| version: '3.8' | |
| # GPU-accelerated version - requires NVIDIA GPU and nvidia-container-toolkit | |
| # Usage: docker-compose -f docker-compose.gpu.yml up | |
| services: | |
| nova-sim: | |
| build: . | |
| ports: | |
| - "3004:5001" | |
| environment: | |
| # Use EGL for GPU rendering (much faster than OSMesa) | |
| - MUJOCO_GL=egl | |
| - PYOPENGL_PLATFORM=egl | |
| # Higher resolution since GPU can handle it | |
| - RENDER_WIDTH=1280 | |
| - RENDER_HEIGHT=720 | |
| - TARGET_FPS=60 | |
| - SIM_STEPS_PER_FRAME=5 | |
| # NVIDIA driver | |
| - NVIDIA_VISIBLE_DEVICES=all | |
| - NVIDIA_DRIVER_CAPABILITIES=graphics,utility,compute | |
| restart: unless-stopped | |
| # Enable GPU access | |
| deploy: | |
| resources: | |
| reservations: | |
| devices: | |
| - driver: nvidia | |
| count: 1 | |
| capabilities: [gpu] | |