From 3560c64121ddf434f8380076300583412a924118 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christoph=20Fr=C3=B6hlich?= Date: Wed, 24 Apr 2024 22:37:18 +0200 Subject: [PATCH] Dockerfile: Specify branch (#284) (cherry picked from commit c4842917f763da4c6c2e85676df920b797588a94) --- Dockerfile/Dockerfile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Dockerfile/Dockerfile b/Dockerfile/Dockerfile index 3b63b741..14ff6792 100644 --- a/Dockerfile/Dockerfile +++ b/Dockerfile/Dockerfile @@ -29,7 +29,11 @@ RUN curl -sSL https://raw.githubusercontent.com/ros/rosdistro/master/ros.key -o RUN mkdir -p /home/ros2_ws/src \ && cd /home/ros2_ws/src \ - && git clone https://github.com/ros-controls/gz_ros2_control/ \ + && if [ "${ROS_DISTRO}" = "rolling" ] ; then \ + git clone https://github.com/ros-controls/gz_ros2_control/; \ + else \ + git clone https://github.com/ros-controls/gz_ros2_control/ -b ${ROS_DISTRO}; \ + fi \ && rosdep init && rosdep update \ && rosdep install --from-paths ./ -i -y --rosdistro ${ROS_DISTRO}