Open qmfrederik opened 7 years ago
That's interesting but I personally have a need for some of the other platform tools as well, though it might be fair to split those into a separate container, then.
Some other concerns:
Android.mk
system with a custom Makefile
. This reminds me of the ubuntu package that was, and perhaps still is, literally years behind the official version.I'm willing to consider this if more people want it, but I think the space savings would be fairly minimal. I do agree that the current glibc hack is quite ugly, though.
This would actually have the benefit of supporting ARM as well.
It's true that the version which ships in Alpine is slightly outdated. I guess they take PRs to their aport repository but I'm not fluent with their package management system. Alternatively, I don't know how difficult it is to build stand-alone adb from the Android repository inside an Alpine container using multi-stage builds and publish that.
This whole issue is intended mainly as a FYI - I'm exploring the area and wanted to share some of the stuff I found, as they may be of interest to you.
Unfortunately it seems that the version on Alpine is already quite old. I'm not sure if I'd want to use that.
@qmfrederik, I'm trying to make a Hass.io addon (read: basically a Docker container) that will run the ADB server, but I'm a Docker rookie and I'm having some trouble. The base image is supposed to be Alpine Linux 3.6. If you're able to offer any help, I would really appreciate it!
Here was my initial attempt. I'm pretty sure I tried the snippet from your first post (although I didn't commit and push it), but it didn't work.
ARG BUILD_FROM
FROM $BUILD_FROM
ENV LANG C.UTF-8
# Install requirements for add-on
RUN apk add --no-cache adb jq
# Copy data for add-on
COPY run.sh /
RUN chmod a+x /run.sh
CMD [ "/run.sh" ]
FYI, there's now a android-tools package in Alpine edge which contains
adb
andfastboot
only. It has been compiled natively for Alpine Linux so you don't need to rely on the glibc package anymore.Here's the command I used to install it on an Alpine container:
This, and upgrading to Alpine 3.6, should help you reduce the container size even further.