mirror of
https://github.com/introlab/rtabmap_ros.git
synced 2026-09-15 07:40:20 +08:00
Docker: added foxy, humble, humble-latest
This commit is contained in:
+3
-4
@@ -29,9 +29,9 @@
|
||||
|
||||
* Launch `rtabmap` from inside the container (**with gui**, if you have a nvidia GPU, follow those [instructions](http://wiki.ros.org/docker/Tutorials/Hardware%20Acceleration#nvidia-docker2) with nvidia-docker2 using one of the images above instead of the ros image example, or for other GPUs try the intel/AMD [instructions](http://wiki.ros.org/action/fullsearch/docker/Tutorials/Hardware%20Acceleration) to build a `rtabmap_ros3d` image with your GPU driver), saving the database on host `~/.ros/rtabmap.db`:
|
||||
|
||||
* With [nvidia-docker2 approach](http://wiki.ros.org/docker/Tutorials/Hardware%20Acceleration#nvidia-docker2), we would have this Dockerfile:
|
||||
* With [nvidia-docker2 approach](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/install-guide.html), we would have this Dockerfile:
|
||||
```docker
|
||||
FROM introlab3it/rtabmap_ros:noetic
|
||||
FROM introlab3it/rtabmap_ros:humble
|
||||
|
||||
# nvidia-container-runtime
|
||||
ENV NVIDIA_VISIBLE_DEVICES \
|
||||
@@ -56,8 +56,7 @@
|
||||
--env="XAUTHORITY=$XAUTH" \
|
||||
--volume="$XAUTH:$XAUTH" \
|
||||
--runtime=nvidia \
|
||||
--env ROS_MASTER_URI=http://172.17.0.1:11311 --env ROS_IP=172.17.0.2 \
|
||||
-v ~/.ros:/root \
|
||||
rtabmap_ros3d \
|
||||
roslaunch rtabmap_ros rtabmap.launch database_path:=/root/rtabmap.db rtabmap_args:="--delete_db_on_start"
|
||||
ros2 launch rtabmap_ros rtabmap.launch.py database_path:=/root/rtabmap.db rtabmap_args:="--delete_db_on_start"
|
||||
```
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
FROM osrf/ros:foxy-desktop
|
||||
# install rtabmap packages
|
||||
ARG CACHE_DATE=2016-01-01
|
||||
RUN apt-get update && apt-get install -y \
|
||||
ros-foxy-rtabmap \
|
||||
ros-foxy-rtabmap-ros \
|
||||
&& rm -rf /var/lib/apt/lists/
|
||||
@@ -0,0 +1,7 @@
|
||||
FROM osrf/ros:humble-desktop
|
||||
# install rtabmap packages
|
||||
ARG CACHE_DATE=2016-01-01
|
||||
RUN apt-get update && apt-get install -y \
|
||||
ros-humble-rtabmap \
|
||||
ros-humble-rtabmap-ros \
|
||||
&& rm -rf /var/lib/apt/lists/
|
||||
@@ -0,0 +1,14 @@
|
||||
FROM introlab3it/rtabmap:22.04
|
||||
|
||||
RUN source /ros_entrypoint.sh && \
|
||||
mkdir -p ros2_ws/src && \
|
||||
cd ros2_ws/src
|
||||
|
||||
COPY . ros2_ws/src/rtabmap_ros
|
||||
|
||||
RUN source /ros_entrypoint.sh && \
|
||||
cd ros2_ws && \
|
||||
export MAKEFLAGS="-j$(nproc)" && \
|
||||
colcon build --event-handlers console_direct+ --install-base /opt/ros/humble --merge-install --cmake-args -DRTABMAP_SYNC_MULTI_RGBD=ON -DCMAKE_BUILD_TYPE=Release && \
|
||||
cd && \
|
||||
rm -rf ros2_ws
|
||||
@@ -0,0 +1,2 @@
|
||||
#!/bin/bash
|
||||
docker build --build-arg CACHE_DATE="$(date)" --cache-from $IMAGE_NAME -f $DOCKERFILE_PATH -t $IMAGE_NAME -t $DOCKER_REPO:humble-latest .
|
||||
Reference in New Issue
Block a user