platform_build/tools/docker
Dan Willemsen c7f16e4fd4 Add USER to the docker environment
Apparently Jack needs this, and my previous testing didn't show it.

Test: build & run image; echo $USER
Change-Id: I66766b230f2f3e0762a49efc9bf2c6212b2b2c4d
2018-04-12 16:41:17 -07:00
..
.gitignore
Dockerfile Add USER to the docker environment 2018-04-12 16:41:17 -07:00
README.md

The Dockerfile in this directory sets up an Ubuntu Trusty image ready to build a variety of Android branches (>= Lollipop). It's particulary useful to build older branches that required 14.04 if you've upgraded to something newer.

First, build the image:

# Copy your host gitconfig, or create a stripped down version
$ cp ~/.gitconfig gitconfig
$ docker build --build-arg userid=$(id -u) --build-arg groupid=$(id -g) --build-arg username=$(id -un) -t android-build-trusty .

Then you can start up new instances with:

$ docker run -it --rm -v $ANDROID_BUILD_TOP:/src android-build-trusty
> cd /src; source build/envsetup.sh
> lunch aosp_arm-eng
> m -j50