https://github.com/jerray/docker-android-builder
https://github.com/jerray/docker-android-builder
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/jerray/docker-android-builder
- Owner: jerray
- Created: 2019-03-02T09:02:49.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2020-03-19T06:46:56.000Z (about 6 years ago)
- Last Synced: 2025-03-11T08:34:53.471Z (over 1 year ago)
- Language: Dockerfile
- Size: 3.91 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Docker Android Builder

Common Android application building environment with Docker.
## Usage
Download an image. Tag `gradle4.1-jdk8-27-27.0.0` means this image contains
gradle 4.1, JDK 8, Android version 27, Android build tools version 27.0.0.
```sh
docker pull jerray/android-builder:gradle4.1-jdk8-27-27.0.0
```
Chnage current directory to your project source root directory.
Run following command to start testing.
```sh
docker run --rm -it \
-v $PWD:/src \
-v $HOME/.gradle:/home/gradle/.gradle \
jerray/android-builder:gradle4.1-jdk8-27-27.0.0 \
gradle test
```
Replace `gradle test` command to any other you want gradle to run.
For example I use `gradle assembleRelease` command to build the `apk` release package.
Parameter `-v $HOME/.gradle:/home/gradle/.gradle` is used to share gradle cache between
host machine and docker container. Removing it will results in gradle downloading depedencies
every time.
## More tool versions
Feel free to make pull requests to add different tool versions. I will merge the pull requests
and make the image available on DockerHub as soon as possible.