Read instructions on the main branch first. To use with ROS, run:
docker run -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY --gpus all sam2-ros-docker bashInside the container, run
source ~/.bashrc
gnome-terminalRun roscore in both machines to find the port being used. Then close the container and rerun with the -p flag:
docker run -it -p [HOST_PORT]:[CONTAINER_PORT] -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY --gpus all sam2-ros-docker bashTo test, run roscore in the docker container and rostopic list on the local host. The local host should show
/rosout
/rosout_agg