
Anbox – Android in a Box - popey
https://mm.gravedo.de/blog/posts/2017-04-10-introducing-anbox/
======
lnanek2
This could be really useful for Android. For example, continuous integration
services like Circle CI are completely useless for UI automation tests because
they don't expose virtualization infrastructure necessary to run the fast x86
emulator. The ARM one is unusably slow (even with dozens of lines of code by
me to try to keep the screen on and unlocked while tests that run in 10
seconds on a dev machine with x86 plod through taking over half an hour on
ARM).

Circle has mentioned in discussions that the virtualization limit will never
be fixed because it is due to them running on Google's cloud services that
don't support it.

They do seem to support LXC, however:
[https://circleci.com/docs/enterprise/config/](https://circleci.com/docs/enterprise/config/)

~~~
zamber
It's not exactly ideal for CI. We had to run uiautomator tests on Jenkins to
get sensible real-world device coverage. On top of that these were a pain to
maintain as each device required things to be done a little differently. Not
to mention the hell we had doing CI on older devices with 4.4.4.

------
newsat13
Can someone explain how badly `snap install --classic anbox-installer` might
mess up my development machine? Can I expect uninstall to properly clean up?

~~~
jumasheff
Anbox in docker should be a good choise here.

~~~
icebraining
It's already using containers (LXC) for running the actual Android system. The
rest of the package contains kernel modules and udev rules, which aren't
suitable for containerization.

------
exabrial
Sort of related: I think Android should consider switching to using cgroups
for each application, rather than a separate user account. This will bring it
more in line with the mainline kernel and maybe we can see some enhancements
there.

~~~
yjftsjthsd-h
It's not a bad idea, but why would that bring them closer to the upstream
kernel? UIDs aren't exactly special; are they doing some extra user
separation?

~~~
exabrial
Yah, id try to explain but I'll get downvoted for not bring completely
correct. It's 'different', there are a bunch of great blog posts on it. Iirc
the biggest problem is Google's patches are pretty useless to the rest of the
Linux community because the security model is so strange

------
funwithjustin
This is pretty cool, but the advent of Android Things might've rendered it
obsolete. My understanding is you can run a custom Android Things image on a
Raspberry Pi 3, and get access to the full Android OS, along with developer
niceties like adb for pushing APKs.

~~~
yebyen
I'm not sure it's really comparable to Android Things... you can run this in
an LXC container on your desktop. With Android Things, unless I've missed
something, you need to start by getting a Development Board from the supported
hardware list.

~~~
mwcampbell
Furthermore, Android Things is designed to run just one application on the
whole machine, whereas Anbox is for running Android apps in a container within
a multitasking environment.

------
israrkhan
This is cool. I guess something similar might be coming from google as part of
unification between android and chrome OS. However this is still very useful
as it can exist outside chrome OS ecosystem.

~~~
jumasheff
My bet goes to Android + Chrome OS + Fuchsia OS

[0][https://en.wikipedia.org/wiki/Google_Fuchsia](https://en.wikipedia.org/wiki/Google_Fuchsia)

------
RussianCow
This is really cool from a technical perspective, but what's the use case? I
can't think of a single Android app that I use that doesn't have an equivalent
desktop/web app that's optimized for a mouse and keyboard. I can't imagine the
UX nightmare of using touch-optimized apps on a regular PC.

~~~
6DM
If you can debug in this, it's got to feel a lot faster than the emulator.
Though I admit I haven't used the emulator in so long that I don't know if
they ever fixed how slow it was.

~~~
HillaryBriss
the emulators got faster about a year ago

[https://infinum.co/the-capsized-eight/say-hello-to-a-
faster-...](https://infinum.co/the-capsized-eight/say-hello-to-a-faster-
android-emulator)

------
skykooler
I wonder whether this could work on Sailfish OS? Currently there is a similar
library called Alien Dalvik, but which is proprietary and can only run on
phones that Jolla officially produces, not ports to other hardware.

------
megablast
This looks quite similar to Samsung's new Dex dock UI. Of course, you don't
need an S8 for this to work. Very interesting.

------
bruce_one
I wonder whether this could be used as a simple way to get an Android env for
Qt development? Last time I did Qt dev for mobile the biggest headaches were
trying to get the Android SDK and NDK configured and setup in a way that
actually worked with Qt :-s

(Similar-ish thought for React Native, although it was much easier than Qt
somehow (so much so that originally I was planning to do the project in Qt and
changed to React Native because everything was up and running much faster).)

~~~
nurettin
Last time I tried Qt for android, the problem wasn't setting up development
kits, but rather, it didn't support the x86 android target in order to run the
fast emulator.

In any case, this is not about development environments, this is about running
android in a chroot jail likr environment directly on linux.

------
mwcampbell
Is this running on ARMv7-based boards yet, or only on x86 machines? The former
would be much more useful for running proprietary Android apps with a native
component.

~~~
bjackman
You might be surprised how many Android apps work on x86 too. Either they are
"fat" (have libraries for multiple ABIs in the .apk) or the Play Store has
multiple versions, and delivers you the one for your platform.

Edit: however, the last FAQ mentions there's a system image for armhf so you
might be in luck anyway :)

------
dharma1
This is wonderful. Was waiting for the Chrome team to open source a their
Android app container code - didn't happen. Will be testing!

------
petecox
I wonder if this could be ported to WSL. Android apps were Microsoft's
original motivation for developing it, after all.

~~~
mwcampbell
That would have limited utility, since many Android apps in the wild assume an
ARM processor.

------
gman83
Can you get Google Play Services on it?

~~~
elastic_church
Otherwise it is useless!

speaking of which, is there a generic push notification system available that
doesn't require Google Play Services?

doesn't seem that hard in theory. websocket service that instructs the
creation of an android notification object

~~~
gman83
[https://pushy.me/](https://pushy.me/)

------
azinman2
Can this be used to run Netflix, HBO Go, etc on Linux?

~~~
zamber
If there's hardware-accelerated video decoding for DRMed streams exposed to
the guest OS then it should. That is if there's a x86 supporting APK for each
one too.

------
basicplus2
Now if I can just do this on my phone to lockout google from everything else..
indeed put every app in a box to stop cross app data theft

------
marknote
Nice! Someone please port it to mac!

------
aashu_dwivedi
I am curious which laptop is being shown on the homepage ?

~~~
MaurizioPz
It looks like an ASUS N550
[https://www.asus.com/it/Notebooks/N550JK/](https://www.asus.com/it/Notebooks/N550JK/)

------
anaganisk
people will definitely come looking for google apps support, so may be since
andbox says "any" app. Maybe just pull opengapps and install it.

------
am185
good job! this looks really cool.

