diff --git a/.docker/ci-testing/Dockerfile b/.docker/ci-testing/Dockerfile index 88ee8eb1ee..45c18e07d6 100644 --- a/.docker/ci-testing/Dockerfile +++ b/.docker/ci-testing/Dockerfile @@ -1,12 +1,20 @@ -# ghcr.io/ros-planning/moveit2:${ROS_DISTRO}-ci-testing +# ghcr.io/ros-planning/moveit2:${OUR_ROS_DISTRO}-ci-testing # CI image using the ROS testing repository -ARG ROS_DISTRO=rolling FROM osrf/ros2:testing LABEL maintainer Robert Haschke rhaschke@techfak.uni-bielefeld.de ENV TERM xterm +# Overwrite the ROS_DISTRO set in osrf/ros2:testing to the distro tied to this Dockerfile (OUR_ROS_DISTRO). +# In case ROS_DISTRO is now different from what was set in osrf/ros2:testing, run `rosdep update` again +# to get any missing dependencies. +# https://docs.docker.com/engine/reference/builder/#using-arg-variables explains why ARG and ENV can't have +# the same name (ROS_DISTRO is an ENV in the osrf/ros2:testing image). +ARG OUR_ROS_DISTRO=rolling +ENV ROS_DISTRO=${OUR_ROS_DISTRO} +RUN rosdep update --rosdistro $ROS_DISTRO + # Install ROS 2 base packages and build tools # We are installing ros--ros-base here to mimic the behavior of the ros:-ros-base images. # This step is split into a separate layer so that we can rely on cached dependencies instead of having diff --git a/.docker/source/Dockerfile b/.docker/source/Dockerfile index f6864cb642..2b9082885e 100644 --- a/.docker/source/Dockerfile +++ b/.docker/source/Dockerfile @@ -4,7 +4,7 @@ # Downloads the moveit source code and install remaining debian dependencies ARG ROS_DISTRO=rolling -FROM ghcr.io/ros-planning/moveit2:${ROS_DISTRO}-ci-testing +FROM moveit/moveit2:${ROS_DISTRO}-ci-testing LABEL maintainer Robert Haschke rhaschke@techfak.uni-bielefeld.de # Export ROS_UNDERLAY for downstream docker containers diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index d6ef85a0d6..8e2959657a 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -31,8 +31,10 @@ jobs: CXXFLAGS: >- -Wall -Wextra -Wwrite-strings -Wunreachable-code -Wpointer-arith -Wredundant-decls CLANG_TIDY_ARGS: --fix --fix-errors --format-style=file - DOCKER_IMAGE: ghcr.io/ros-planning/moveit2:${{ matrix.env.IMAGE }} - UPSTREAM_WORKSPACE: moveit2.repos $(f="moveit2_$(sed 's/-.*$//' <<< "${{ matrix.env.IMAGE }}").repos"; test -r $f && echo $f) + DOCKER_IMAGE: moveit/moveit2:${{ matrix.env.IMAGE }} + UPSTREAM_WORKSPACE: > + moveit2.repos + $(f="moveit2_$(sed 's/-.*$//' <<< "${{ matrix.env.IMAGE }}").repos"; test -r $f && echo $f) # Pull any updates to the upstream workspace (after restoring it from cache) AFTER_SETUP_UPSTREAM_WORKSPACE: vcs pull $BASEDIR/upstream_ws/src # Uninstall binaries that are duplicated in the .repos file diff --git a/.github/workflows/docker.yaml b/.github/workflows/docker.yaml index ff37875017..55e382cac3 100644 --- a/.github/workflows/docker.yaml +++ b/.github/workflows/docker.yaml @@ -131,7 +131,7 @@ jobs: uses: docker/build-push-action@v4 with: file: .docker/${{ github.job }}/Dockerfile - build-args: ROS_DISTRO=${{ matrix.ROS_DISTRO }} + build-args: OUR_ROS_DISTRO=${{ matrix.ROS_DISTRO }} push: ${{ env.PUSH }} no-cache: true tags: |