Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[🐛 Bug ]: Emulator not starting #454

Open
Bebrevski opened this issue Aug 18, 2024 · 3 comments
Open

[🐛 Bug ]: Emulator not starting #454

Bebrevski opened this issue Aug 18, 2024 · 3 comments
Labels

Comments

@Bebrevski
Copy link

Operating System

Ubuntu

Docker Image

budtmo/docker-android:emulator_14.0

Expected behaviour

Run command and get booted emulator

          docker run -d --privileged -p 6080:6080 -p 5555:5555 -p 5554:5554 -e EMULATOR_DEVICE=samsung_galaxy_s10_14.0 -e WEB_VNC=true --device /dev/kvm --name android-container budtmo/docker-android:emulator_14.0
          docker ps
          adb kill-server
          adb devices
          sleep 30 && adb connect localhost:5555

Guys, no matter what i do I always get the same result. Just can't find/connect the emulator. I am trying to run it for e2e Detox test on Codemagic platform. I will really appreciate any help and advices i can get.

Keep in mind that this "emulator-5554" might be the Codemagic preinstalled emulator. It is android 11 (very old), so i can't use it. If i try command like docker exec -it android-container adb devices i get an empty list of devices.

Actual behaviour

Just can't find/connect to emulator no matter what i do

Logs

e40c4e9b277cd5857ec28fa583bbfbb6bf3d1900b8e9abdc50229b10d239142d
CONTAINER ID   IMAGE                                 COMMAND                  CREATED         STATUS                  PORTS                                                                                                                                    NAMES
e40c4e9b277c   budtmo/docker-android:emulator_14.0   "/home/androidusr/do…"   5 seconds ago   Up Less than a second   4723/tcp, 0.0.0.0:5554-5555->5554-5555/tcp, :::5554-5555->5554-5555/tcp, 5900/tcp, 9000/tcp, 0.0.0.0:6080->6080/tcp, :::6080->6080/tcp   android-container
cannot connect to daemon at tcp:5037: Connection refused
* daemon not running; starting now at tcp:5037
* daemon started successfully
List of devices attached
emulator-5554	offline

e40c4e9b277cd5857ec28fa583bbfbb6bf3d1900b8e9abdc50229b10d239142d
CONTAINER ID   IMAGE                                 COMMAND                  CREATED         STATUS                  PORTS                                                                                                                                    NAMES
e40c4e9b277c   budtmo/docker-android:emulator_14.0   "/home/androidusr/do…"   5 seconds ago   Up Less than a second   4723/tcp, 0.0.0.0:5554-5555->5554-5555/tcp, :::5554-5555->5554-5555/tcp, 5900/tcp, 9000/tcp, 0.0.0.0:6080->6080/tcp, :::6080->6080/tcp   android-container
cannot connect to daemon at tcp:5037: Connection refused
* daemon not running; starting now at tcp:5037
* daemon started successfully
List of devices attached
emulator-5554	offline

failed to connect to localhost:5555
failed to connect to localhost:5555
@Bebrevski Bebrevski added the bug label Aug 18, 2024
@Bebrevski Bebrevski changed the title [🐛 Bug ]: [🐛 Bug ]: Emulator not starting Aug 18, 2024
@slavawar
Copy link

Hi! Do you have the image available at localhost:6080? What do you see there?

@Bebrevski
Copy link
Author

Hi! Do you have the image available at localhost:6080? What do you see there?

Hi. I have empty image of "Docker Android" or something like that. I decided to run everything localy on VM and I managed to run the emulator. Now I am trying to figure out why detox tests are timeouting. The whole story is very complicated. The setup and behavior is totally different on the platforms. I guess I need a ton of test for better understanding. As I sad, my goal now is to run everything localy and after that to migrate all to pipeline.

@slavawar
Copy link

Please note that if you run it on Windows, there will be problems with kvm and therefore image virtualization may not start. There is no such problem on Ubuntu.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants