Quick Start with Dev Container
Using a development container (Dev Container) is the fastest and easiest way to get started with AimRT development. It provides a fully configured development environment without the need to manually install any dependencies.
What is a Dev Container
A development container (Dev Container) is a complete development environment that runs inside a Docker container. It includes:
A pre-configured operating system (Ubuntu 22.04 + ROS2 Humble)
All required build tools and dependencies
VS Code extensions and configurations
The complete environment needed for AimRT development
System Requirements
Before using the development container, you need to install the following on your local system:
Windows
macOS
Linux
Proxy Configuration
If you are in a corporate network environment or need to access the internet through a proxy, you may encounter network connectivity issues when building the development container. In this case, you need to configure Docker proxy settings. Please refer to the following official documentation:
Quick Start Steps
1. Clone the Repository
git clone https://github.com/AimRT/AimRT.git
cd AimRT
2. Open the Project in VS Code
code .
3. Start the Development Container
When you open the project in VS Code, you will see a popup in the bottom right corner:
Folder contains a Dev Container configuration file. Reopen in container?
Click the “Reopen in Container” button.
Alternatively, you can start it manually:
Press
Ctrl+Shift+P
(Windows/Linux) orCmd+Shift+P
(macOS) to open the command paletteType
Dev Containers: Reopen in Container
Select the command and press Enter
4. Wait for Container Build to Complete
On first launch, Docker will:
Download the base image (approximately 1-2 GB)
Build the development container (about 5-10 minutes, depending on network speed)
Install all dependencies and development tools
Subsequent launches will be faster as the image is cached.
5. Start Development
Once the container starts, you will have a complete AimRT development environment:
Build the project:
./build.sh
Development Container Features
Pre-installed Tools and Environment
Operating System: Ubuntu 22.04
ROS2: Humble version with environment variables configured
Build Tools:
CMake 3.28.0
GCC/Clang compilers
Rust toolchain (for Zenoh plugin)
Python Environment:
Python 3.10
Pre-installed necessary packages (pyinstaller, jinja2, pyyaml, etc.)
Development Dependencies:
All system libraries required for AimRT compilation
VS Code Extensions
The container automatically installs the following extensions:
llvm-vs-code-extensions.vscode-clangd
- C++ language support and code navigationms-vscode.cmake-tools
- CMake supportms-python.python
- Python language supporteamodio.gitlens
- Git enhancementsmjohns.clang-format
- Code formattingredhat.vscode-yaml
- YAML support
Port Forwarding
The container automatically forwards the following ports:
2222
- SSH port (for remote access)
FAQ
Q: What if the first startup is very slow?
A: The first startup requires downloading and building the image, please be patient. Ensure a stable network connection. If in mainland China, the container will automatically detect and use domestic mirror sources to accelerate downloads.
Q: How to access build results outside the container?
A: Build results are saved in the build
folder in the project directory, which is shared between the host and container.
Q: How to rebuild the container?
A: Select Dev Containers: Rebuild Container
in the command palette to rebuild the container.
Q: Does the container take up a lot of space?
A: The complete development container takes up about 3-4 GB of disk space.
Next Steps
After successfully starting the development container, we recommend:
Read the Hello World example to start your first AimRT program
Learn about AimRT core concepts
Explore more example programs