Giter Site home page Giter Site logo

antonshbk / ros-2-humble-docker Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 37.37 MB

This tutorial is designed as a basis for further projects written using the ROS framework. Here we create containers for quick and convenient work in them.

License: Apache License 2.0

Dockerfile 100.00%
dokcer ros-humble ros2

ros-2-humble-docker's Introduction

drawing

ROS2 HUMBLE DOCKER GUI

This tutorial is designed as a basis for further projects written using the ROS framework. Here we create containers for quick and convenient work in them. Containers can be launched separately manually via Dockerfile or via docker-compose, depending on the preference and the necessary functionality. It also describes the settings for using GUI applications inside Docker.

gide

Pre-installation:

  • Get Docker desktop installed and running by following this Guide
  • Ensure WSL-2 is installed or upgraded from WSL-1 from this link
  • Install VcXsrv Windows X Server from this link

User gide docker-composer

Before starting the container, you need to configure and start the X server (VcXsrv). Using the VcXsrv its a simple approach to connect GUI in Docker container and localhost machine. You can learn more here.

Detailed configuration of ROS GUI support. If you want more setting read here.

drawing | drawing drawing | drawing

Run docker-compose (multiruning)

If you want to use docker-compose in your projects. Build containers.

docker-compose build
  • Run containers.
docker-compose up

In order to use docker-compose tools correctly, you should study docker-compose.yml and also refer to the technical documentation. In this repository, I used environment variables that are rendered in this file .env . They are used when building containers, as well as when launching containers via docker-compose.

All the necessary dependencies for Python are placed in the requirements folder. There are 2 files in this folder common.txt this is a file with the main dependencies and developmet.txt which contains files for debugging if necessary. This is done in order to use a container for production.

Useful source source of information Github.

If such an error occurs, it means that an incorrect command was entered or such a module is not installed

/ros_entrypoint.sh: line 6: exec: rviz: not found

User gide Dockerfile

  • Running a container with GUI enabled for Windows
docker run -it --name <container name> -e DISPLAY=host.docker.internal:0.0  bin/bash

Useful commands for containers

  • Creating a interactive container from image
docker run -it <image name>
  • Giving Name to a container while creating
docker run --name <container name> <image name>
  • Start a stopped Container
docker start (container_id)
  • Connect shell to running container
docker exec -it (container_id) bin/bash

Building Image from Docker File

  • Terminal from same directory
docker built -t <image name > .

ros-2-humble-docker's People

Contributors

antonshbk avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.