Closed ArcherEmiya05 closed 5 months ago
Thanks for reporting. Should be fixed in https://github.com/mindrunner/docker-android-sdk/commit/7a459cff3010a36b36ae3cdbf5b78f4c251bf396
It still happening. Below is my whole script.
- $ANDROID_HOME/tools/bin/sdkmanager --list # Print the Android SDK's list of installed and available packages, install packages, and update packages https://developer.android.com/tools/sdkmanager#usage
- echo no | $ANDROID_HOME/tools/bin/avdmanager create avd -n EMU --abi google_apis_playstore/x86_64 -k "system-images;android-34;google_apis_playstore;x86_64" # Create an Android Virtual Device named EMU, the specified ABI and system image will be use for this emulator
- $ANDROID_HOME/tools/emulator -avd EMU -no-window -no-audio -no-boot-anim & adb wait-for-device # Start emulator without any visual or audio output and block until device is online https://android.googlesource.com/platform/system/core/+/4f6e8d7a00cbeda1e70cc15be9c4af1018bdad53/adb/commandline.c#143
- ./gradlew connectedAndroidTest --continue # Start instrumented test
- $ANDROID_HOME/platform-tools/adb devices | grep emulator | cut -f1 | while read line; do $ANDROID_HOME/platform-tools/adb -s $line emu kill; done # Kill all running emulator
In the new Android SDK these are the new paths btw.
$ANDROID_HOME/cmdline-tools/latest/latest/sdkmanager
$ANDROID_HOME/cmdline-tools/latest/latest/avdmanager
$ANDROID_HOME/emulator/emulator
Sorry about that. Please try with latest
build:
sdkmanager --list
sdkmanager --install "system-images;android-34;google_apis_playstore;x86_64"
avdmanager create avd -n EMU --abi google_apis_playstore/x86_64 -k "system-images;android-34;google_apis_playstore;x86_64"
emulator -avd EMU -no-window -no-audio -no-boot-anim & adb wait-for-device
works for me now
Sorry about that. Please try with
latest
build:sdkmanager --list sdkmanager --install "system-images;android-34;google_apis_playstore;x86_64" avdmanager create avd -n EMU --abi google_apis_playstore/x86_64 -k "system-images;android-34;google_apis_playstore;x86_64" emulator -avd EMU -no-window -no-audio -no-boot-anim & adb wait-for-device
works for me now
Thanks a lot! Will try it now
Still not working, I am using it in Bitbucket Pipelines but I don't think it will be an issue right?
- step: # Step to run instrumented test with aggregated results on all module. Bitbucket test reporting is automatically enabled https://support.atlassian.com/bitbucket-cloud/docs/test-reporting-in-pipelines/
size: 2x # 2x steps use twice the number of build minutes of a 1x step
name: Instrumented Test (Aggregated)
image: runmymind/docker-android-sdk:latest # Docker for Android SDK with pre-installed build tools and emulator image https://github.com/mindrunner/docker-android-sdk
caches: # Caching speed up subsequent execution https://support.atlassian.com/bitbucket-cloud/docs/cache-dependencies/
- gradle
Or I no longer need to specify the path/directory with this image to use the command-line tools?
It seems that I no longer need to specify the ANDROID HOME
and path for sdkmanager
however another issue occurred with avdmanager
Error: Package path is not valid. Valid system image paths are:
null
the sdkmanager --list command
does not show system-images;android-34;google_apis_playstore;x86_64
it seems that the image is using package-list-minimal.txt
? Will try docker-android-sdk:ubuntu-lazydl
instead.
I tried runmymind/docker-android-sdk:ubuntu-lazydl
and it fails
bash: sdkmanager: command not found
For now I just manually install the image that I was gonna use when using the standalone runmymind/docker-android-sdk:latest
to fix the issues
sdkmanager "system-images;android-34;google_apis_playstore;x86_64"
Of course the image need to be installed:
See https://github.com/mindrunner/docker-android-sdk/issues/100#issuecomment-2081601638
I tried
runmymind/docker-android-sdk:ubuntu-lazydl
and it fails
bash: sdkmanager: command not found
Anyway, worth noting
Using
runmymind/docker-android-sdk:latest