osrf / icra2023_ros2_gz_tutorial

ICRA 2023 tutorial on ROS 2 and the new Gazebo (MT28, ICC Capital Suite 14)
Apache License 2.0
229 stars 33 forks source link

Initial Dockerfile #1

Closed mabelzhang closed 1 year ago

mabelzhang commented 1 year ago

Initial Dockerfile with NVIDIA + ROS 2 Humble + Gazebo Garden binary installs.

To test, follow README.md.

Future work

mabelzhang commented 1 year ago

As of b1e9b80 and 2f99a72, the Dockerfile should now work for both NVIDIA and no-NVIDIA. The difference is in the base image. By default, it will build with the NVIDIA base image. Use --no-nvidia flag with build.bash to build with the ubuntu:jammy image.

A note (thanks @iche033) on xauth block in run.bash: Re these messages:

xauth:  /tmp/.docker.xauth not writable, changes will be ignored
xauth: (argv):1:  unable to read any entries from file "(stdin)"
chmod: changing permissions of '/tmp/.docker.xauth': Operation not permitted

I replaced the hardcoded :0 with $DISPLAY in 2f99a72. Chris, see if that makes those messages go away for you. For me, the block does nothing either way, as it doesn't have permission to create the /tmp/.docker.xauth file. It's just an empty directory for me, but the GUIs work, so I've always ignored those messages. I added a Troubleshoot note in README to ignore it. If the behavior is different for you, we'll want to fix that block so that it actually gets rid of the errors, and document that in the README.