This repository was archived by the owner on Jan 3, 2019. It is now read-only.
forked from sorccu/docker-adb
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
35 lines (29 loc) · 1.29 KB
/
Copy pathDockerfile
File metadata and controls
35 lines (29 loc) · 1.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
FROM alpine:3.4
# Set up insecure default key
RUN mkdir -m 0750 /root/.android
ADD files/insecure_shared_adbkey /root/.android/adbkey
ADD files/insecure_shared_adbkey.pub /root/.android/adbkey.pub
ADD files/update-platform-tools.sh /usr/local/bin/update-platform-tools.sh
RUN set -xeo pipefail && \
apk update && \
apk add wget ca-certificates tini && \
wget -O "/etc/apk/keys/sgerrand.rsa.pub" \
"https://raw.githubusercontent.com/andyshinn/alpine-pkg-glibc/master/sgerrand.rsa.pub" && \
wget -O "/tmp/glibc.apk" \
"https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.23-r3/glibc-2.23-r3.apk" && \
wget -O "/tmp/glibc-bin.apk" \
"https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.23-r3/glibc-bin-2.23-r3.apk" && \
apk add "/tmp/glibc.apk" "/tmp/glibc-bin.apk" && \
rm "/etc/apk/keys/sgerrand.rsa.pub" && \
rm "/root/.wget-hsts" && \
rm "/tmp/glibc.apk" "/tmp/glibc-bin.apk" && \
rm -r /var/cache/apk/APKINDEX.* && \
/usr/local/bin/update-platform-tools.sh
# Expose default ADB port
EXPOSE 5037
# Set up PATH
ENV PATH $PATH:/opt/platform-tools
# Hook up tini as the default init system for proper signal handling
ENTRYPOINT ["/sbin/tini", "--"]
# Start the server by default
CMD ["adb", "-a", "-P", "5037", "server", "nodaemon"]