How to Install Docker on the Qualcomm® Robotics RB3 development platform

Preparing the board to pull the ROS image from a container

Docker makes it easier to package an application into containers and run it in different development environments. Using a container simplifies the process of making ROS, an open-source meta-operating system for robots, available to the Qualcomm Robotics RB3 development platform. (Note that it is possible to install ROS without Docker, but that currently requires installing multiple dependencies.)

As described in Flashing a New, Complete Image (from Linaro) onto the Board, the image from Linaro has been successfully tested with Docker and a container for ROS. ROS does not need to be inside a Docker container, but that is currently the simplest procedure for getting ROS to work on the Qualcomm Robotics RB3 development platform.

Update the Qualcomm Robotics RB3 development board

Flash the board with the latest version of the Linaro Debian desktop image.

Set up Docker

  1. To pull images from Docker, first create a Docker account.

  2. Uninstall old versions of Docker.

    $ sudo apt-get remove docker docker-engine containerd runc

Install Docker using the repository

Set up the repository

  1. Update the apt package index:

    $ sudo apt-get update
  2. Install packages to allow HTTPS:

    $ sudo apt-get install apt-transport-https ca-certificates curl gnupg2 software-properties-common
  3. Add Docker’s official GPG Key:

    $ curl -fsSL | sudo apt-key add –
  4. Verify the key with fingerprint:

    $ sudo apt-key fingerprint 0EBFCD88
    pub 4096R/0EBFCD88 2017-02-22
    Key fingerprint = 9DC8 5822 9FC7 DD38 854A E2D8 8D81 803C 0EBF CD88
    uid Docker Release (CE deb)
    sub 4096R/F273FCD8 2017-02-22

  5. Set up the Stable repository for arm64 platform:

    $ sudo add-apt-repository "deb [arch=arm64] $(lsb_release -cs) stable"

Install Docker Engine - Community

$ sudo apt-get update
$ sudo apt-get install docker-ce docker-ce-cli

Troubleshooting iptables

Once you run the foregoing commands, you may see an error indicating failure, as in this screenshot:

Check the version of Docker:

$ sudo docker version

The screenshot below indicates that the Docker Engine is installed, but the daemon is not running.

Launch Docker:

$ sudo service docker start

The following error message will appear:

The problem is that the Docker installer uses iptables for network address translation (NAT). However, Debian uses a modified version of nftables. One option is to convert the entries to nftables.

Alternately, you can set Debian up to use iptables-legacy by running these commands:

$ sudo update-alternatives --set iptables /usr/sbin/iptables-legacy
$ sudo update-alternatives --set ip6tables /usr/sbin/ip6tables-legacy

Restart Docker:

$ sudo service docker start

Running ROS

Once Docker is running, pull a ROS image:

docker pull ros

Qualcomm Robotics RB3 is a product of Qualcomm Technologies, Inc. and/or its subsidiaries.