Basically, osrf/ros images with my personal tweaks.
183
I added X11 forwarding to the /ros_entrypoint.sh using environment variables $DISPLAY and $MMC1 (for the MIT magic cookie).
Using a bridge network appropriately named ros_net:
docker run --rm -e DISPLAY=${DISPLAY} -e MMC1=${MMC1} -e ROS_MASTER_URI=http://ros_master:11311 --network=ros_net -v "/tmp/.X11-unix:/tmp/.X11-unix" -v "/home/username/catkin_ws/src:/root/catkin_ws/src" --name ros_master -it davidovrat/ros:melodic-desktop-full
If running on multiple hosts, use the host network and export ROS_IP=<host's IP> on the running containers so the ROS master would know how to find them. If running on a bridge network, give each container a unique name and only the the one running roscore should be named ros_master. Map the container's /root/catkin_ws/src directory to your own, then catkin_make install and source devel/setup.bash and you're good to go.
From the ros workspace src directory,
docker run --rm -e DISPLAY=${DISPLAY} -e MMC1=${MMC1} --network=host -v "/tmp/.X11-unix:/tmp/.X11-unix" -v $PWD:/root/dev_ws/src --name foxy -it davidovrat/ros:foxy
Enjoy!
Content type
Image
Digest
sha256:a1a66511d…
Size
308 MB
Last updated
almost 4 years ago
docker pull davidovrat/ros:foxy