Go2Py_SIM/deploy/docker/Dockerfile.nav2

32 lines
1.3 KiB
Docker
Raw Normal View History

# FROM isaac_ros_dev-aarch64
FROM ros:humble
ENV DEBIAN_FRONTEND=noninteractive
SHELL ["/bin/bash", "-c"]
# uodate and install dependencies
RUN apt-get update && apt-get install -y \
ros-humble-rmw-cyclonedds-cpp ros-humble-rosidl-generator-dds-idl \
libyaml-cpp-dev \
libboost-all-dev\
build-essential \
cmake \
git \
ros-humble-nav2-* ros-humble-navigation2 \
2024-05-31 02:44:51 +08:00
ros-humble-slam-toolbox \
ros-humble-robot-localization\
ros-humble-image-geometry \
&& rm -rf /var/lib/apt/lists/*
# Cheange the ROS2 RMW to CycloneDDS as instructed by Unitree
RUN cd / && git clone https://github.com/unitreerobotics/unitree_ros2 && cd /unitree_ros2/cyclonedds_ws/src && \
git clone https://github.com/ros2/rmw_cyclonedds -b humble && git clone https://github.com/eclipse-cyclonedds/cyclonedds -b releases/0.10.x &&\
cd .. && colcon build --packages-select cyclonedds && source /opt/ros/humble/setup.bash && colcon build
# copy the go2py ros2 nodes
2024-05-31 02:44:51 +08:00
COPY ros2_nodes/sportmode_nav2 /nav2_ws/src/sportmode_nav2
COPY ros2_nodes/m-explore-ros2 /nav2_ws/src/m-explore-ros2
2024-05-31 02:44:51 +08:00
COPY ros2_nodes/go2py_messages /nav2_ws/src/go2py_messages
RUN cd /nav2_ws && source /opt/ros/humble/setup.bash && source /unitree_ros2/cyclonedds_ws/install/setup.bash && colcon build --symlink-install
# set the entrypoint to bash
ENTRYPOINT ["/bin/bash"]