Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
documentation:containers [2023/01/17 17:31] – [Prerequisites] marcusk | documentation:containers [2024/06/19 07:32] (current) – marcusk | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Containers ====== | ====== Containers ====== | ||
- | ==== Prerequisites ==== | + | ===== Prerequisites |
* Ubuntu 18.04, 20.04, 22.04 | * Ubuntu 18.04, 20.04, 22.04 | ||
Line 10: | Line 10: | ||
* //Optional but useful:// Nvidia Docker if you have a Nvidia GPU: https:// | * //Optional but useful:// Nvidia Docker if you have a Nvidia GPU: https:// | ||
- | ==== SSH Keys ==== | + | ===== SSH Keys ===== |
It can be configured in a number of ways, below is a suggestion: | It can be configured in a number of ways, below is a suggestion: | ||
Line 29: | Line 29: | ||
</ | </ | ||
- | You need to add your key ('' | + | You need to add your key ('' |
https:// | https:// | ||
Line 37: | Line 37: | ||
</ | </ | ||
- | ==== ROS Containers Quickstart ==== | + | ===== ROS Containers Quickstart |
Valuable information about how to use ROS Containers exists in the repository readme: | Valuable information about how to use ROS Containers exists in the repository readme: | ||
https:// | https:// | ||
- | === Clone the ROS-containers repository === | + | ==== Clone the ROS-containers repository |
<cli> | <cli> | ||
git clone git@git.cs.lth.se: | git clone git@git.cs.lth.se: | ||
Line 48: | Line 48: | ||
</ | </ | ||
- | === Set options === | + | ==== Set options |
There are many options, all start with '' | There are many options, all start with '' | ||
Line 61: | Line 61: | ||
</ | </ | ||
- | Both above requires your user to have '' | + | Both above requires your user to have '' |
+ | |||
+ | If you intend to run this with a real robot: | ||
+ | < | ||
+ | make use-real | ||
+ | </ | ||
+ | This adds '' | ||
More options are available in the documentation: | More options are available in the documentation: | ||
- | === Build and run === | + | ==== Build and run ==== |
<cli> | <cli> | ||
make run | make run | ||
Line 72: | Line 78: | ||
This will build the base image, a special user image where your user is known and mapped and finally a container to run it all in. | This will build the base image, a special user image where your user is known and mapped and finally a container to run it all in. | ||
- | By default your home directory is mapped to '' | + | By default your home directory is mapped to '' |
- | === Resume and reset === | + | ==== Resume and reset ==== |
Delete your container to change mappings or otherwise clean out your environment: | Delete your container to change mappings or otherwise clean out your environment: | ||
<cli> | <cli> | ||
Line 85: | Line 91: | ||
</ | </ | ||
- | This command will resume your container.// | + | This command will resume your container. |
+ | // Note:// if the container is resumed in one terminal and you resume again, you will effectly use the same terminal interface in multiple terminals (they will be mirrored). | ||
Line 91: | Line 98: | ||
You should have succeeded in building the container and is inside it for below to work. | You should have succeeded in building the container and is inside it for below to work. | ||
- | === Build the Heron Workspace === | + | ==== Build the Heron Workspace |
<cli> | <cli> | ||
workspace init heron.rosinstall | workspace init heron.rosinstall | ||
Line 97: | Line 104: | ||
</ | </ | ||
- | === Run Heron simulation === | + | ==== Run Heron simulation |
Two terminals or tmux/start roscore in background: | Two terminals or tmux/start roscore in background: | ||
Line 114: | Line 121: | ||
</ | </ | ||
+ | |||
+ | ===== Workspace Tips/Tricks ===== | ||
+ | |||
+ | ==== Using a custom rosinstall ==== | ||
+ | Let say it is named '' | ||
+ | |||
+ | - Copy your '' | ||
+ | - In your home directory, run '' | ||
+ | - This will clone all the repos described in '' | ||
+ | |||
+ | **Note:** '' | ||
+ | |||
+ | ==== Switching branches ==== | ||
+ | By default '' | ||
+ | If you modify it, you can run '' | ||
+ | |||
+ | If you are using ROS2, it would be called '' | ||
+ | |||
+ | **Note**: '' | ||
+ | ====== Resources ====== | ||
+ | ===== WSL 2 GPU Drivers ===== | ||
+ | https:// | ||
+ | |||
+ | ===== VS Code Workflow ===== | ||
+ | The files in the home folder (in the container) are by default available in '' | ||
+ | |||
+ | To attach your VS Code to the running Docker container, choose the Docker panel and right-click on the container to get a context menu. | ||
+ | |||
+ | {{: | ||