Skip to content

Move helper binaries target location

What does this MR do?

This MR changes slightly the output location for:

  • the helper binaries to go under out/binaries/runner-helper instead of out/binaries/gitlab-runner-helper so that they don't get added by a filter that specified the runner binaries out/binaries/gitlab-runner-*;
  • the runner binaries to go under out/binaries/runner;
  • the binaries subfolders which now match the subfolder names under dockerfiles/.

Previous (good) state

job artifacts
binaries windows/386 windows/amd64 3 matching files
binaries linux/386 linux/amd64 linux/arm linux/arm64 5 matching files

Current (master) state

job artifacts
binaries windows/386 windows/amd64 8 matching files and directories
binaries linux/386 linux/amd64 linux/arm linux/arm64 linux/s390x 11 matching files and directories

MR (good) state

job artifacts
binaries windows/386 windows/amd64 3 matching files and directories
binaries linux/386 linux/amd64 linux/arm linux/arm64 6 matching files and directories

Why was this MR needed?

See #26560 (closed).

The change in the target location for the helper binaries introduced in !2114 (merged) caused the helper binaries to inadvertently be captured in the artifacts for the .binaries-derived jobs. This MR changes slightly the output location for the helper binaries to go under out/binaries/runner-helper instead of out/binaries/gitlab-runner-helper so that they don't get added by a filter that specified the runner binaries out/binaries/gitlab-runner-*. We also move the gitlab-runner binaries to out/binaries/runner for consistency.

What's the best way to test this MR?

  • Ensure that the .binaries-derived jobs only contain the runner binaries, not the helper binaries. (See issue description)

  • Ensure that make helper-dockerarchive-host still works.

    rm -rf out/binaries/{gitlab-runner-helper,runner-helper}/ && \
      docker rmi -f "gitlab/gitlab-runner-helper:x86_64-$(git rev-parse --short=8 HEAD)" && \
      make helper-dockerarchive-host && ls -al out/binaries/runner-helper/gitlab-runner-helper.x86_64 && \
      docker images list --filter=reference='gitlab/gitlab-runner-helper' | grep "$(git rev-parse --short=8 HEAD)" && \
      echo 'Success!'
  • Ensure that make runner-bin-host still works:

    rm -rf out/binaries/{gitlab-runner,runner/} && \
      make runner-bin-host && \
      ls -al out/binaries/runner/gitlab-runner && \
      echo 'Success!'

What are the relevant issue numbers?

Closes #26560 (closed)

Merge request reports