Skip to content

Conversation

rprichard
Copy link
Contributor

@rprichard rprichard commented Aug 21, 2025

In docker-compose.yml, add *image_versions arguments for the android-buildkite-builder service, so that ACTIONS_BASE_IMAGE is set (to builder-base). This will also set the BASE_IMAGE, which we don't really want, because this service uses ubuntu:noble instead of the ubuntu:jammy default, but that's OK because the setting is successfully overridden.

In vendor/android/run-buildbot-container, use the correct ghcr.io Docker path (ghcr.io/llvm/libcxx-android-builder).

Reenable the build-and-push of ghcr.io/llvm/libcxx-android-builder in the libcxx-build-containers.yml workflow.

In docker-compose.yml, add *image_versions arguments for the
android-buildkite-builder service, so that ACTIONS_BASE_IMAGE is set
(to builder-base). This will also set the BASE_IMAGE, which we don't
really want, because this service uses ubuntu:noble instead of the
ubuntu:jammy default, but that's OK because the setting is successfully
overridden.

In vendor/android/run-buildbot-container, use the correct ghcr.io
Docker path (ghcr.io/llvm/libcxx-android-builder). (This Docker image
doesn't actually exist at ghcr.io (yet), but it is the name produced
by the Docker compose file.)
@rprichard rprichard requested a review from a team as a code owner August 21, 2025 23:19
@llvmbot llvmbot added the libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. label Aug 21, 2025
@llvmbot
Copy link
Member

llvmbot commented Aug 21, 2025

@llvm/pr-subscribers-github-workflow

@llvm/pr-subscribers-libcxx

Author: Ryan Prichard (rprichard)

Changes

In docker-compose.yml, add *image_versions arguments for the android-buildkite-builder service, so that ACTIONS_BASE_IMAGE is set (to builder-base). This will also set the BASE_IMAGE, which we don't really want, because this service uses ubuntu:noble instead of the ubuntu:jammy default, but that's OK because the setting is successfully overridden.

In vendor/android/run-buildbot-container, use the correct ghcr.io Docker path (ghcr.io/llvm/libcxx-android-builder). (This Docker image doesn't actually exist at ghcr.io (yet), but it is the name produced by the Docker compose file.)


Full diff: https://github.com/llvm/llvm-project/pull/154856.diff

2 Files Affected:

  • (modified) libcxx/utils/ci/docker-compose.yml (+1-1)
  • (modified) libcxx/utils/ci/vendor/android/run-buildbot-container (+1-1)
diff --git a/libcxx/utils/ci/docker-compose.yml b/libcxx/utils/ci/docker-compose.yml
index ccaee8c896ded..44f9e6354ff51 100644
--- a/libcxx/utils/ci/docker-compose.yml
+++ b/libcxx/utils/ci/docker-compose.yml
@@ -37,4 +37,4 @@ services:
         ANDROID_CLANG_VERSION: r563880
         ANDROID_CLANG_PREBUILTS_COMMIT: 6ae4184bb8706f9731569b9a0a82be3fcdcb951c
         ANDROID_SYSROOT_COMMIT: f8b85cc5262c6e5cbc9a92c1bab2b18b32a4c63f
-        <<: *compiler_versions
+        <<: [*image_versions, *compiler_versions]
diff --git a/libcxx/utils/ci/vendor/android/run-buildbot-container b/libcxx/utils/ci/vendor/android/run-buildbot-container
index 7b5d9a4cc3fe7..81c719b1f8b96 100755
--- a/libcxx/utils/ci/vendor/android/run-buildbot-container
+++ b/libcxx/utils/ci/vendor/android/run-buildbot-container
@@ -27,5 +27,5 @@ if [ -S /var/run/docker.sock ]; then
     DOCKER_OPTIONS+=(--volume /var/run/docker.sock:/var/run/docker.sock)
 fi
 
-docker run "${DOCKER_OPTIONS[@]}" ghcr.io/libcxx/android-buildkite-builder \
+docker run "${DOCKER_OPTIONS[@]}" ghcr.io/llvm/libcxx-android-builder \
     bash -c 'git config --global --add safe.directory /llvm; (/opt/android/container-setup.sh && exec bash)'

Copy link
Contributor

@boomanaiden154 boomanaiden154 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Disabling the android libcxx builder in CI is disabled (

# - name: Build the Android builder image
). You should reenable it in this patch if you want it get uploaded to GHCR and not break in the future.

@rprichard
Copy link
Contributor Author

Okay, I re-enabled the build of the main Android Docker image. Currently the GCE VMs for Android use three Docker image paths that aren't public (the main image, and two images that each contain the Android Emulator and an Android system image).

Once we have a public Docker image with the Android Clang + sysroot, I can switch the GCE VM over to using it, so that updating the Dockerfile will automatically update what the Android GCE VMs are using. I think that's an improvement.

Maybe we could also build the two emulator images, as well? Currently I've been building them by hand (libcxx/utils/ci/vendor/android/build-emulator-images.sh) and pushing them to the private Artifact Registry path that the VMs use.

Copy link
Contributor

@boomanaiden154 boomanaiden154 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To fix the CI container build you'll need to configure docker daemon to use the space in /mnt rather than the default location.

https://evodify.com/change-docker-storage-location/ should have info.

Not sure why GHA hosted runners have disk space bifurcated between the main drive and /mnt, but it is the way it is.

Copy link
Contributor

@boomanaiden154 boomanaiden154 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Please wait for one of the libc++ maintainers to review before merging this though.

Copy link
Member

@ldionne ldionne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this!

@ldionne ldionne merged commit 6b45060 into llvm:main Aug 28, 2025
70 of 79 checks passed
@rprichard rprichard deleted the fix-android-dockerfile branch August 29, 2025 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github:workflow libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants