spiri-sdk/docker-compose.yml

53 lines
1.6 KiB
YAML
Raw Permalink Normal View History

2024-11-01 12:20:08 -03:00
version: "3.8"
2024-09-17 12:30:08 -03:00
services:
gui-tools:
2024-10-25 14:49:07 -03:00
env_file:
- .env
build:
context: ./guiTools/
environment:
# Display settings
- DISPLAY=${DISPLAY}
- WAYLAND_DISPLAY=${WAYLAND_DISPLAY}
# - QT_QPA_PLATFORM=${QT_QPA_PLATFORM:-xcb} # Default to X11
# If running with Wayland
- XDG_RUNTIME_DIR=${XDG_RUNTIME_DIR}
- ROS_MASTER_URI=http://ros-master:11311
2024-10-03 17:25:09 -03:00
# - NVIDIA_DRIVER_CAPABILITIES=compute,video,utility
# - NVIDIA_VISIBLE_DEVICES=all
volumes:
# X11 socket
- /tmp/.X11-unix:/tmp/.X11-unix
2024-09-19 14:33:29 -03:00
- ${XAUTHORITY:-~/.Xauthority}:/root/.Xauthority
# Wayland socket
#- ${XDG_RUNTIME_DIR}/wayland-0:${XDG_RUNTIME_DIR}/wayland-0
# Allow access to the host's GPU
- /dev/dri:/dev/dri
2024-11-05 11:22:15 -04:00
#Auto reload on code changes
- ./guiTools/spiri_sdk_guitools/:/app/spiri_sdk_guitools/
# Enable launching the SDK from the SDK
# - ./:/app/sdk
- ./robots:/robots
- /var/run/docker.sock:/var/run/docker.sock
devices:
# Provide access to GPU devices
- /dev/dri:/dev/dri
2024-10-25 14:49:07 -03:00
network_mode: host
ports:
- 8923:8923
ipc: host
2024-09-19 14:33:29 -03:00
#user: "${UID}:${GID}"
2024-11-01 12:20:08 -03:00
privileged: true # Allow privileged access if necessary (e.g., for GPU access)
# restart: unless-stopped
# command: /bin/bash -c "source /opt/ros/foxy/setup.bash && rvis2" # Replace with the actual command to run Gazebo Ignition
deploy:
resources:
reservations:
devices:
- driver: cdi
device_ids:
- nvidia.com/gpu=all