This is a Dockerfile for Android build projects.
- OpenJDK 8
- Gradle 2.2
- platform-tools,build-tools
- Android SDK (android-19、21、22、23、24)
- Android Support Libraries
Build docker image
docker build -t jmcn/android_build_gradle2.2 .
Run docker image
docker run --rm \
-v ~/project:/project \
-v ~/.gradle:/root/.gradle \
jmcn/android_build_gradle2.2:latest /bin/bash -c "cd /project;gradle assembleRelease";
use
-v
to mount yourandroid project directory
andgradle cache