forked from yongjhih/docker-android-studio
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
30 lines (20 loc) · 932 Bytes
/
Dockerfile
File metadata and controls
30 lines (20 loc) · 932 Bytes
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
FROM yongjhih/android:jdk8-all
RUN dpkg --add-architecture i386 && \
apt-get update && apt-get install -y --no-install-recommends sudo lib32z1 lib32ncurses5 lib32stdc++6 lib32z1 lib32ncurses5 lib32stdc++6 && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
ENV ANDROID_STUDIO /opt/android-studio
ENV ANDROID_STUDIO_VERSION 2.1.0.9
ENV ANDROID_STUDIO_URL https://dl.google.com/dl/android/studio/ide-zips/${ANDROID_STUDIO_VERSION}/android-studio-ide-143.2790544-linux.zip
ADD $ANDROID_STUDIO_URL /tmp/tmp.zip
RUN unzip /tmp/tmp.zip -d /opt && rm /tmp/tmp.zip
ENV USER ubuntu
ENV UID 1000
RUN useradd -m -u $UID $USER && \
echo "$USER ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers && \
chmod -R a+w ${ANDROID_HOME}
#USER $USER
ADD docker-entrypoint.sh /
ENTRYPOINT ["/docker-entrypoint.sh"]
#CMD ["${ANDROID_STUDIO}/bin/studio.sh"] # will not do variable substitution
CMD ["/opt/android-studio/bin/studio.sh"]