alpine-android
alpine-android copied to clipboard
Can compile app that targets 33 on alpine-android:android-30-jdk11 image
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?
Hello @iamarjun,
that is because it downloads the SDK version according to the compileSDK. Here is a log using android-30-jdk11:
/home/android/katana # ./gradlew assembleDebug
Downloading https://services.gradle.org/distributions/gradle-7.5.1-bin.zip
...........10%............20%...........30%............40%...........50%............60%...........70%............80%...........90%............100%
Configuration cache is an incubating feature.
Configuration on demand is an incubating feature.
Type-safe project accessors is an incubating feature.
:common:jar: No valid plugin descriptors were found in META-INF/gradle-plugins
Checking the license for package Android SDK Build-Tools 33 in /opt/sdk/licenses
License for package Android SDK Build-Tools 33 accepted.
Preparing "Install Android SDK Build-Tools 33 (revision: 33.0.0)".
"Install Android SDK Build-Tools 33 (revision: 33.0.0)" ready.
Installing Android SDK Build-Tools 33 in /opt/sdk/build-tools/33.0.0
"Install Android SDK Build-Tools 33 (revision: 33.0.0)" complete.
"Install Android SDK Build-Tools 33 (revision: 33.0.0)" finished.
Checking the license for package Android SDK Platform 33 in /opt/sdk/licenses
License for package Android SDK Platform 33 accepted.
Preparing "Install Android SDK Platform 33 (revision: 2)".
"Install Android SDK Platform 33 (revision: 2)" ready.
Installing Android SDK Platform 33 in /opt/sdk/platforms/android-33
"Install Android SDK Platform 33 (revision: 2)" complete.
"Install Android SDK Platform 33 (revision: 2)" finished.
This will increase CI times, so to avoid downloading the correct SDK and build tools, is better to use the same version.
If you would like to turn that functionality off (maybe to ensure the CI never spends time to download and install the required components repeatedly): Put android.builder.sdkDownload=false into gradle.properties.