79 lines
2.2 KiB
Docker
79 lines
2.2 KiB
Docker
FROM osrf/ros:humble-desktop-full
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
ENV ROS_DISTRO=humble
|
|
ENV WS=/root/piper_ws
|
|
|
|
# System dependencies and build tools
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
git \
|
|
python3-pip \
|
|
python3-colcon-common-extensions \
|
|
python3-rosdep \
|
|
ros-humble-moveit \
|
|
ros-humble-moveit-planners-ompl \
|
|
ros-humble-moveit-ros-planning-interface \
|
|
ros-humble-moveit-ros-move-group \
|
|
ros-humble-moveit-visual-tools \
|
|
ros-humble-geometric-shapes \
|
|
ros-humble-octomap \
|
|
ros-humble-octomap-msgs \
|
|
ros-humble-octomap-ros \
|
|
ros-humble-robot-state-publisher \
|
|
ros-humble-joint-state-publisher \
|
|
ros-humble-joint-state-publisher-gui \
|
|
ros-humble-rviz2 \
|
|
ros-humble-xacro \
|
|
ros-humble-moveit-resources-panda-moveit-config \
|
|
ros-humble-moveit-resources-panda-description \
|
|
ros-humble-joint-state-broadcaster \
|
|
ros-humble-joint-trajectory-controller \
|
|
ros-humble-position-controllers \
|
|
ros-humble-gripper-controllers \
|
|
nano \
|
|
curl \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Python libraries for geometry, scene graph processing & point clouds
|
|
RUN pip3 install --no-cache-dir \
|
|
numpy \
|
|
scipy \
|
|
plyfile \
|
|
trimesh \
|
|
transforms3d \
|
|
pyyaml
|
|
|
|
# Setup ROS 2 workspace and clone AgileX Piper ROS (humble branch)
|
|
RUN mkdir -p ${WS}/src
|
|
WORKDIR ${WS}/src
|
|
|
|
# Clone piper_ros and submodules
|
|
RUN git clone -b humble https://github.com/agilexrobotics/piper_ros.git \
|
|
&& cd piper_ros \
|
|
&& git submodule update --init --recursive || true
|
|
|
|
WORKDIR ${WS}
|
|
|
|
# Install any remaining rosdep dependencies
|
|
RUN . /opt/ros/humble/setup.sh \
|
|
&& apt-get update \
|
|
&& rosdep update \
|
|
&& rosdep install --from-paths src --ignore-src -r -y || true \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Build the workspace
|
|
RUN . /opt/ros/humble/setup.sh \
|
|
&& colcon build --symlink-install --cmake-args -DCMAKE_BUILD_TYPE=Release
|
|
|
|
# Setup entrypoint environment
|
|
RUN echo "source /opt/ros/humble/setup.bash" >> /root/.bashrc \
|
|
&& echo "source ${WS}/install/setup.bash" >> /root/.bashrc
|
|
|
|
COPY entrypoint.sh /entrypoint.sh
|
|
RUN chmod +x /entrypoint.sh
|
|
|
|
WORKDIR /workspace
|
|
|
|
ENTRYPOINT ["/entrypoint.sh"]
|
|
CMD ["bash"]
|