From 2f44b07a88e9bbef3c415e5ab9e7001a22a34c00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steven!=20Ragnar=C3=B6k?= Date: Fri, 18 Mar 2022 13:22:58 -0700 Subject: [PATCH] Perform all apt operations except those targeting the ROS repositories before daily invalidation. There is no reason that these installations should be performed after the daily cache bust. As far as I can tell their presence here is entirely accidental. The ROS 1 packages being installed after invalidation makes some sense since ROS distributions change more frequently than the base Ubuntu or Debian release. --- linux_docker_resources/Dockerfile | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/linux_docker_resources/Dockerfile b/linux_docker_resources/Dockerfile index 7a5f3c6a8..b78a62cc5 100644 --- a/linux_docker_resources/Dockerfile +++ b/linux_docker_resources/Dockerfile @@ -135,21 +135,6 @@ RUN apt-get update && apt-get install --no-install-recommends -y libtinyxml-dev # Install Python3 development files. RUN apt-get update && apt-get install --no-install-recommends -y python3-dev -# automatic invalidation once every day. -RUN echo "@today_str" - -# Install build and test dependencies of ros1_bridge if there is a valid ROS 1 distro. -RUN if test ${BRIDGE} = true -a -n "${ROS1_DISTRO}"; then apt-get update && apt-get install --no-install-recommends -y \ - ros-${ROS1_DISTRO}-catkin \ - ros-${ROS1_DISTRO}-common-msgs \ - ros-${ROS1_DISTRO}-rosbash \ - ros-${ROS1_DISTRO}-roscpp \ - ros-${ROS1_DISTRO}-roslaunch \ - ros-${ROS1_DISTRO}-rosmsg \ - ros-${ROS1_DISTRO}-roscpp-tutorials \ - ros-${ROS1_DISTRO}-rospy-tutorials \ - ros-${ROS1_DISTRO}-tf2-msgs; fi - # Install dependencies for RViz visual tests RUN apt-get update && apt-get install --no-install-recommends -y \ libgl1-mesa-dri \ @@ -165,6 +150,21 @@ RUN apt-get update && apt-get install -y \ libacl1-dev \ libncurses5-dev +# automatic invalidation once every day. +RUN echo "@today_str" + +# Install build and test dependencies of ros1_bridge if there is a valid ROS 1 distro. +RUN if test ${BRIDGE} = true -a -n "${ROS1_DISTRO}"; then apt-get update && apt-get install --no-install-recommends -y \ + ros-${ROS1_DISTRO}-catkin \ + ros-${ROS1_DISTRO}-common-msgs \ + ros-${ROS1_DISTRO}-rosbash \ + ros-${ROS1_DISTRO}-roscpp \ + ros-${ROS1_DISTRO}-roslaunch \ + ros-${ROS1_DISTRO}-rosmsg \ + ros-${ROS1_DISTRO}-roscpp-tutorials \ + ros-${ROS1_DISTRO}-rospy-tutorials \ + ros-${ROS1_DISTRO}-tf2-msgs; fi + # After all packages are installed, update ccache symlinks (see ros2/ci#326). # This command is supposed to be invoked whenever a new compiler is installed # but that isn't happening. So we invoke it here to make sure all compilers are