Step-by-step Workflow to Install Docker and ROS on Windows PC

Google

  1. 1. Go to www.google.com

  2. 2. Type "docker install windows"

  3. 3. Click on Install Docker Desktop on Windows

    Click on Install Docker Desktop on Windows
  4. 4. Click on Docker Desktop for Windows

    Click on Docker Desktop for Windows
  5. 5. Download and Install Docker for Windows

    After installation, there is a Mandatory Restart required to finish installation.

    Download and Install Docker for Windows
  6. 6. Type "download xlaunch "

    Type "download xlaunch "
  7. 7. Click on VcXsrv Windows X Server download | SourceForge.net

    Click on VcXsrv Windows X Server download | SourceForge.net

Docker

  1. 8. Click on Download

    Click on Download
  2. 9. Download and Install to be able to GUIs inside Docker

    Download and Install to be able to GUIs inside Docker

Google

  1. 10. Open Terminal to check if Docker is installed

    Hit the Windows Icon > CMD > Docker

    This will show you a bunch of available Docker commands which is a sign that you have successfully installed Docker.

    Open Terminal to check if Docker is installed
  2. 11. Hit Windows > Docker Desktop to launch

    You might get the access denied error. If so, fix it using the next step otherwise skip to the Launch step.

    Hit Windows > Docker Desktop to launch

Sourceforge

  1. 12. Add yourself to the Docker User group using the command shown below

    Be sure to run the Command Prompt as Admin

    Add yourself to the Docker User group using the command shown below
  2. 13. Update WSL Kernel, if prompted

    Update WSL Kernel, if prompted
  3. 14. Verify that the Windows Subsystem for Linux is installed

    Verify that the Windows Subsystem for Linux is installed
  4. 15. Launch Docker Desktop

    Launch Docker Desktop
  5. 16. Click on Google Search

    Click on Google Search

Stackoverflow

  1. 17. Click on osrf/ros - Docker Image

    Click on osrf/ros - Docker Image
  2. 18. Click on docker pull osrf/ros2:<tag_name>…

    Click on docker pull osrf/ros2:<tag_name>…
  3. 19. Pull OSRF Ros2 Foxy Image from Docker

    docker pull osrf/ros:foxy-desktop

    Pull OSRF Ros2 Foxy Image from Docker
  4. 20. Test that ROS image has been successfully added to Docker

    Docker > Images

    You can pull multiple images of ROS1 and ROS 2 which will all be listed here and you can easily manage them here. This is the power of Docker.

    Test that ROS image has been successfully added to Docker
  5. 21. Launch a new docker Container with respective ROS Image

    docker run --name ros2-foxy -it osrf/ros:foxy-desktop

    For all available Docker commands, check out: https://docs.docker.com/engine/reference/run/

    Launch a new docker Container with respective ROS Image

Google

  1. 22. Launch your Nodes and enjoy using ROS/ ROS2

    Depending on the corresponding version of ROS you use, you can execute your respective nodes.

    Remember "roscore" doesn't exist in ROS2

    Launch your Nodes and enjoy using ROS/ ROS2
  2. 23. Single OS, multiple ROS Version, No version conflict

    On a single Ubuntu 20.04 on top of your Windows PC, you can now easily run ROS1 and ROS2 without having to mess around with Ubuntu Versions and ROS Version incompatibilities.

    Single OS, multiple ROS Version, No version conflict