diff --git a/Dockerfile/Dockerfile b/Dockerfile/Dockerfile index 325ced18..2da32969 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}