2

About

I am developing a piece of software which consists of a Node.js application which controls a virtual machine that runs Android-x86. Also there are some pieces of the Android SDK like ADB the software depends on.

My current approach

Currently there is no smart way of deployment whatsoever at all. Everything has to be installed manually. Depending on the system I also get issues regarding networking and so on from time to time.

To solve problems of these kinds I usually would use Docker. Therefore that was my first thought here as well. So such a Docker container would simply run the Node.js application as well as the virtual machine.

My problem

For me it became a bit confusing (and maybe even pointless) when I wanted to use a virtual machine inside of a Docker container. Due to there is obviously no way I can run an Android-x86 Docker container I cannot come up with any other solution than a virtual machine inside of Docker.

My question

Is it fine to do as I mentioned or are there any better ways or even best practices to use a virtual machine inside of a container?

Edits

  • I want to add that a possible solution does not have to be utilizing Docker. If there is any other technology that is able to create a container-ish construct which in further consequence is able to run a virtual machine I would be happy to get to know it.

1 Answer 1

2

Frankly, I've never seen running a VM inside Docker. I believe it would be very slow. Have you checked if https://github.com/budtmo/docker-android is useful?

This Video talks about the Docker and Android SDK as well - https://www.youtube.com/watch?v=YwBAqMDYFCU

1
  • Thanks for the contribution! Speed is not too much of a problem for my purpose to be honest. I checked out projects like the one you linked, yes. They all use the Android Emulator instead of the Android-x86 project. I probably can make it work with an Android emulator as well but I prefer the Android-x86 approach.
    – Bee
    Commented Oct 17, 2019 at 14:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.