alvr / alpine-android Goto Github PK
View Code? Open in Web Editor NEW๐ Small docker image for building & testing Android applications.
Home Page: https://alvr.dev
License: Apache License 2.0
๐ Small docker image for building & testing Android applications.
Home Page: https://alvr.dev
License: Apache License 2.0
As per https://android-developers.googleblog.com/2020/12/announcing-android-gradle-plugin.html AGP 7.0.0 will require JDK 11. I noted that you upgraded to JDK11 and then downgraded again.
May be worth having a JDK11 version of this project?
The CI I have set up that uses this docker image suddenly stopped working and it appears to be related to the newest release.
This was using alvrme/alpine-android:android-30-jdk11
:
Images used:
build : docker.io/alvrme/alpine-android@sha256:c39202e4da263bb66bfc65a49bdba941f97bebc91c7ca9d48617fccb0b97acc8
+ ./gradlew ktlintCheck --no-parallel
ERROR: JAVA_HOME is set to an invalid directory: /opt/java/openjdk
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation.
Hi. Is it possible to upgrade to Kotlin 1.6?
I use latest alvrme/alpine-android:android-33-jdk11
And some time ago my builds started to fail with the following error.
[ERROR] The git-push command failed.
[ERROR] Command output:
[ERROR] error: cannot run ssh: No such file or directory
I just use git push using scm:git:ssh://
connection, which is common use case for maven-release-plugin
Inside container:
bash-5.1# ssh -V
bash: ssh: command not found
bash-5.1# find / -name "ssh" -type f
bash-5.1#
Seems like bellsoft/liberica-openjdk-alpine removed ssh binary from their image
Hey, I just started testing this docker image and it's working perfectly.
I would like to hear your opinion on how to avoid downloading gradlew and mvn dependencies on every build.
Thanks!
Hey!
With today's update, one of my pipelines broke because I was using an old Gradle wrapper version not compatible with java 11.
Is there any chance you can start tagging versions so users can go to an old version if necessary?
Thanks!
Hello -
Docker tag: android-31-jdk11
distributionUrl=https://services.gradle.org/distributions/gradle-7.4.2-bin.zip
Issues - in our CICD Pipeline, we are using the "alpine-android" docker image. Recently we updated our Docker image to support jdk11 we are seeing this issue. Any help would be really helpful and much appreciated.
Thanks in advance.
Since the 21st update
Using Docker executor with image alvrme/alpine-android:android-30 ...
Using locally found image version due to if-not-present pull policy
Using docker image sha256:bfdb4e27da52668a0cd1874260fe301338a24f481d1643188b670d9c2e1e57d5 for alvrme/alpine-android:android-30 ...
...
$ ./gradlew -q assembleProdRelease
Checking the license for package Android SDK Build-Tools 30.0.2 in /opt/sdk/licenses
License for package Android SDK Build-Tools 30.0.2 accepted.
Preparing "Install Android SDK Build-Tools 30.0.2 (revision: 30.0.2)".
"Install Android SDK Build-Tools 30.0.2 (revision: 30.0.2)" ready.
Installing Android SDK Build-Tools 30.0.2 in /opt/sdk/build-tools/30.0.2
"Install Android SDK Build-Tools 30.0.2 (revision: 30.0.2)" complete.
"Install Android SDK Build-Tools 30.0.2 (revision: 30.0.2)" finished.
Checking the license for package Android SDK Platform 30 in /opt/sdk/licenses
License for package Android SDK Platform 30 accepted.
Preparing "Install Android SDK Platform 30 (revision: 3)".
"Install Android SDK Platform 30 (revision: 3)" ready.
Installing Android SDK Platform 30 in /opt/sdk/platforms/android-30
"Install Android SDK Platform 30 (revision: 3)" complete.
"Install Android SDK Platform 30 (revision: 3)" finished.
while before with
Using Docker executor with image alvrme/alpine-android:android-30 ...
Using locally found image version due to if-not-present pull policy
Using docker image sha256:2386ebeccf176ec891787989713329e3df4b32bc73b82fdb130e79f655e64945 for alvrme/alpine-android:android-30 ...
...
$ ./gradlew -q assembleProdRelease
Did not install anything
PS: build-tools 30.0.3 was just released
Hi @alvr,
First of all, thank you for this beautiful image, it immensely helped us with our CD system,
So recently we updated one of our 2 apps to android 12 and to my surprise we didn't have to update our image to the matching version, and everything seems to work fine. To test this further we migrated the other app to android 13 and surprisingly the same image worked for the android 13 targeting app.
Am I missing anything here or is this some magic happening here?
Adding fastlane to android-30-jdk11
seems to fail.
Dockerfile
FROM alvrme/alpine-android:android-30-jdk11
RUN extras fastlane
docker build -t builder .
Sending build context to Docker daemon 3.072kB
Step 1/2 : FROM alvrme/alpine-android:android-30-jdk11
---> 6633c34baa73
Step 2/2 : RUN extras fastlane
---> Running in d0448a74ac71
fetch https://dl-cdn.alpinelinux.org/alpine/v3.14/main/x86_64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.14/community/x86_64/APKINDEX.tar.gz
(1/24) Installing libstdc++ (10.3.1_git20210424-r2)
(2/24) Installing binutils (2.35.2-r2)
(3/24) Installing libgomp (10.3.1_git20210424-r2)
(4/24) Installing libatomic (10.3.1_git20210424-r2)
(5/24) Installing libgphobos (10.3.1_git20210424-r2)
(6/24) Installing gmp (6.2.1-r0)
(7/24) Installing isl22 (0.22-r0)
(8/24) Installing mpfr4 (4.1.0-r0)
(9/24) Installing mpc1 (1.2.1-r0)
(10/24) Installing gcc (10.3.1_git20210424-r2)
(11/24) Installing musl-dev (1.2.2-r3)
(12/24) Installing libc-dev (0.7.2-r3)
(13/24) Installing g++ (10.3.1_git20210424-r2)
(14/24) Installing make (4.3-r0)
(15/24) Installing gdbm (1.19-r0)
(16/24) Installing yaml (0.2.5-r0)
(17/24) Installing ruby-libs (2.7.4-r0)
(18/24) Installing ruby (2.7.4-r0)
(19/24) Installing libgmpxx (6.2.1-r0)
(20/24) Installing pkgconf (1.7.4-r0)
(21/24) Installing gmp-dev (6.2.1-r0)
(22/24) Installing libucontext (1.1-r0)
(23/24) Installing libucontext-dev (1.1-r0)
(24/24) Installing ruby-dev (2.7.4-r0)
Executing busybox-1.33.1-r2.trigger
Executing glibc-bin-2.33-r0.trigger
/usr/glibc-compat/sbin/ldconfig: /usr/glibc-compat/lib/ld-linux-x86-64.so.2 is not a symbolic link
OK: 236 MiB in 57 packages
No version specified, using latest
ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions for the /usr/lib/ruby/gems/2.7.0 directory.
The command '/bin/sh -c extras fastlane' returned a non-zero code: 1
Hello and thank you very much for these great images! We are using them for our CI/CD and it's working fine. However, the steps always download the Gradle wrapper and download various things like the emulator before it starts building. Would it be possible to include them in the image already? This would require different images for different Gradle versions, but it would be very time-saving for us.
Thanks!
With the release of JDK 17, is it possible to add that as a column to the matrix?
Thanks!
error: cannot run ssh: No such file or directory
fatal: unable to fork
Failed to clone 'apiplatform' a second time, aborting
Since the update yesterday none of our pipelines run anymore.
Caused by: java.util.ServiceConfigurationError: javax.annotation.processing.Processor: android.databinding.annotationprocessor.ProcessDataBinding Unable to get public no-arg constructor
4649 at kotlin.collections.CollectionsKt___CollectionsKt.toCollection(_Collections.kt:1200)
4650 at kotlin.collections.CollectionsKt___CollectionsKt.toMutableList(_Collections.kt:1233)
4651 at kotlin.collections.CollectionsKt___CollectionsKt.toList(_Collections.kt:1224)
4652 at org.jetbrains.kotlin.kapt3.base.ProcessorLoader.doLoadProcessors(ProcessorLoader.kt:80)
4653 at org.jetbrains.kotlin.kapt3.base.ProcessorLoader.loadProcessors(ProcessorLoader.kt:45)
4654 at org.jetbrains.kotlin.kapt3.base.Kapt.kapt(Kapt.kt:42)
4655 ... 29 more
4656 Caused by: java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException
4657 ... 35 more
4658 Caused by: java.lang.ClassNotFoundException: javax.xml.bind.JAXBException
4659 ... 35 more
I think it's related to the jdk11 update.
How can we fix this or can you provide an image with the old jdk?
I am in a weird situation where AGP 8.0 needs JDK 17, but I need to configure Kotlins jvmToolChain
to 11. Do you think it would be possible?
I was at Droidcon UK, and there was mention that an upgrade to JDK 19 makes a noticeable build improvement.
Do you have any plans for JDK 19?
I'm also kind of person who usually uses the latest JDK possible - Do you have thoughts about pointing the latest image to the latest JDK?
Android 14 will be using latest
tag on January 1st, 2024.
The latest release of Android Studio Flamingo came along with the new Android Gradle Plugin 8.0.0. This version of the plugin requires Java 17 to run. To avoid problems with CI/CD configurations, Java 17 will be the default JDK for versions released on or after July 1st, 2024. In other words, if you are using currently latest
tag, from July 1st, 2024, it will use Java 17 instead of Java 11.
Since v2018.02.17, this image included all versions from API 21 onwards. Android 5 was released on 2014, thats 7 years ago and Google ended its support long time ago. New versions of Alpine Android published from Novemeber 1st, 2021 will only generate tags for API 28 and newer versions.
The latest release of Android Studio 2020.3.1 came along with the new Android Gradle Plugin 7.0.0. This version of the plugin requires Java 11 to run. To avoid problems with CI/CD configurations, Java 11 will be the default JDK for versions released on or after July 28th, 2022. In other words, if you are using currently latest
tag, from July 28th, 2022, it will use Java 11 instead of Java 8.
Hi,
Thanks a lot for creating the slim alpine images for Docker. Would it be possible for you to add support for Arm64/v8 arch? I've an Apple Silicon M1 macbook and other images don't work on it.
I tried forking this repo, but didn't go far as there are a lot of changes required with credentials etc.
We could leverage the platforms
argument of the Docker buildx action?
- name: Build Android Base JDK${{ matrix.jdk }}
uses: docker/build-push-action@v2
with:
context: ./docker
file: ./docker/base.Dockerfile
push: true
tags: ${{ steps.docker_meta.outputs.tags }}
build-args: |
JDK_VERSION=${{ matrix.jdk }}
# Limit to platforms supported by base image
platforms: |
linux/arm64/v8
Here is a PR the has the relevant build .yml file that builds for arm64/v8 arch:
docker/setup-buildx-action#54
Looks like BellSoft is recommending Alpaquita Linux as an replacement for Alpine to use in containers with Liberica JDK: https://github.com/bell-sw/Liberica/blob/master/docker/repos/liberica-openjdk-alpine-musl/README.md#alpaquita-linux-is-a-free-and-advanced-replacement-for-alpine-to-use-in-containers-with-liberica-jdk
I wanted to use: alvrme/alpine-android:android-30-jdk8
from DockerHub.
But docker fail in runtime while app build on /opt/java/openjdk/jre/lib/amd64/libfontmanager.so: libfreetype.so.6: cannot open shared object file: No such file or directory
I just found to it: docker-library/openjdk#335
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.