Build Android apps on Linux x86-64 using the Android SDK and Java build tools.
- OpenJDK 17 from the pinned Beevelop Java image
- Gradle 8.14.8, Apache Maven, and Apache Ant
- Android SDK Command-Line Tools 22.0 and Android Platform Tools
- Android SDK platforms 34, 35, 36, 37.0, and 37.2
- Android SDK Build Tools 36.0.0 and 37.0.0
The image includes Gradle 8.14 for projects that still need Gradle 8. Command-Line Tools 22 retains a self-contained sdkmanager for automation. Use your project's ./gradlew to select the version the project requires.
docker pull --platform linux/amd64 beevelop/android:latest
docker run --rm --platform linux/amd64 beevelop/android:latest sdkmanager --versionPin a release tag in your CI from the published releases. On an ARM host, Docker needs x86-64 emulation to run this image. Both ANDROID_HOME and ANDROID_SDK_ROOT point to /opt/android.
Read Google's Android SDK license terms and accept the licenses for your user or build image before installing more SDK packages or running tools that require acceptance. The image ships without accepted licenses. You can install legacy add-ons and other platforms with sdkmanager if your project needs them.
From the cloned repository:
docker buildx build --platform linux/amd64 --load -t android:local .
docker run --rm --platform linux/amd64 android:local gradle --version
docker run --rm --platform linux/amd64 android:local aapt2 versionThe Dockerfile pins the Java base by digest. To adopt a new parent image, replace the pinned digest in the Dockerfile before running CI. When Dependabot opens the update, review the digest change and the PR checks.
To test against java:local in your Docker engine’s image store, use a Buildx builder with the docker driver. Check the builder name with docker buildx ls and substitute it for default if needed.
docker buildx build --builder default --platform linux/amd64 --load \
--build-arg JAVA_IMAGE=java:local -t android:local .With the docker-container driver, set JAVA_IMAGE to an image reference in a registry the builder can access.
| Badge | Docker Hub | Build Status | Published | Release / Tag | License |
|---|---|---|---|---|---|
