Created
June 4, 2022 11:50
-
-
Save huhuang03/ecca29e6ce2bc918b89655650f2f7101 to your computer and use it in GitHub Desktop.
android dockerfile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:14.04 | |
ARG username=root | |
RUN sed -i s@/archive.ubuntu.com/@/mirrors.163.com/@g /etc/apt/sources.list | |
RUN apt-get update && apt-get install -y git-core gnupg flex bison gperf build-essential zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z-dev ccache libgl1-mesa-dev libxml2-utils xsltproc unzip python openjdk-7-jdk | |
RUN apt install -y vim | |
ENV HTTP_PROXY="http://192.168.0.5:7890" | |
ENV HTTPS_PROXY=$HTTP_PROXY | |
RUN echo "alias jump='export http_proxy=\"$HTTP_PROXY\" && export https_proxy=\"$HTTP_PROXY\"'" >> ~/.bashrc | |
RUN echo "alias unjump='unset http_proxy && unset https_proxy'" >> ~/.bashrc | |
RUN curl -o jdk8.tgz https://android.googlesource.com/platform/prebuilts/jdk/jdk8/+archive/master.tar.gz \ | |
&& tar -zxf jdk8.tgz linux-x86 \ | |
&& mv linux-x86 /usr/lib/jvm/java-8-openjdk-amd64 \ | |
&& rm -rf jdk8.tgz | |
RUN curl -o /usr/local/bin/repo https://storage.googleapis.com/git-repo-downloads/repo \ | |
# && echo "d06f33115aea44e583c8669375b35aad397176a411de3461897444d247b6c220 /usr/local/bin/repo" | sha256sum --strict -c - \ | |
&& chmod a+x /usr/local/bin/repo | |
ENV USER=$username | |
ENV no_proxy=127.0.0.1,localhost |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment