MoveIt 1 Docker Install

Docker is an open-source project that automates the deployment of Linux applications inside software containers. Docker is an open-source project that automates the deployment of Linux applications inside software containers.


Docker can help you easily evaluate someone else’s code changes without changing your local setup, as well as test on versions of Linux other than your locally installed one. MoveIt has an official MoveIt Docker build that lets you quickly run MoveIt in a local container.

Installing Docker

Before starting this tutorial, please complete the installation as described in Docker’s installation instructions. Installation instructions are available for multiple operating systems.


Note that for recent Linux distros, the installation is basically just a single wget command. You may also want add your user to the docker group to avoid having to use sudo permissions when you use the docker command.

Ubuntu

If you are running a recent version of Ubuntu (e.g. 16.04, 18.04) it can be as simple as:

sudo apt install curl
curl -sSL https://get.docker.com/ | sh
sudo usermod -aG docker $(whoami)

And you will likely need to log out and back into your user account for the changes to take effect.

Running MoveIt Containers

To use Rviz (and other GUIs), you probably want to set up hardware acceleration for Docker as described here.


The next step is to download the gui-docker script that handles everything to get your docker up and running with graphical user interfaces such as RViz and Gazebo. To download the script run the following command:

curl -o gui-docker \
https://raw.githubusercontent.com/ros-planning/moveit/master/.docker/gui-docker && \
chmod +x gui-docker

Then, the wrapper script gui-docker can be used to correctly setup the docker environment for graphics support. For example, you can run the MoveIt docker container using the following command to pull the current noetic source build. If you want to pull the docker image for other distributions, see official MoveIt Docker Hub Repository for available docker images.

./gui-docker -it --rm moveit/moveit:noetic-source /bin/bash

You can test that the GUI works by running rviz:

roscore > /dev/null & rosrun rviz rviz

As the previous command dropped the --rm option, the container will be persistent, so changes you make inside the container will remain.

Running gui-docker in multiple terminals will connect them all to the same container. For convienence, the script defines sensible defaults. For example running the following command will try to pull the docker image containing the current master branch's source build namely, moveit/moveit:master-source, and if there already exists a container with this image, will directy connect to that container.

./gui-docker

Quick Start

Start planning in Rviz with:

MoveIt Getting Started Tutorial

MoveIt Container Types

There are many variants of the MoveIt Docker available as documented here. For example, any of the two current distros work: [melodic, noetic]. Other variations include:

moveit/moveit:master-source

contains a full MoveIt workspace downloaded and built to ~/ws_moveit/src. This container is useful for developers wanting to test or develop in a sandbox.

moveit/moveit:melodic-release

builds ontop of the CI image, the full debian-based install of MoveIt using apt.

moveit/moveit:master-ci

an image optimized for running continuous integration with Travis

moveit/moveit:master-ci-shadow

an image optimized for running continuous integration with Travis using the latest unreleased build of ROS

Troubleshooting

"source devel/setup.bash" does not work / MoveIt packages are not found

In the moveit/moveit:master-source container, "install/setup.bash" needs to be sourced instead of "devel/setup.bash".


Error response from daemon: OCI runtime create failed...

Your container may have an issue. Try

1. Deleting it by:

docker stop default_container && docker rm default_container


2. And running:

gui-docker again.