I'd like to use GitLab CI system for my Android application gradle project. The project repository is hosted on GitLab.com, so I'd like to use one of the Shared Runners provided by Gitlab Inc.
While the official tutorial provides an example for NodeJS project runner configuration and there are also shared runners for Ruby projects, I couldn't find any example or even a runner that supports Android applications.
- Is there a shared runner provided by GitLab.com, which supports Android projects out of the box (by specifying
image: android:4.2.2
or something like this)? - Is there a way to configure existing shared runner provided by GitLab.com to support Android projects (by modifying the .gitlab-ci.yml file)?
This is the
.gitlab-ci.yml
file which I'm using in my android project. Since I changed it to install one component at a time it is pretty stable. Sometimes the licence can't be accepted and the build fails. But that's a rare case. It is important that your build-tools are the same as in this script (build-tools-23.0.3
) maybe you have to change the script here.You can leave out the
artifacts
declaration I use it to get the lint report.UPDATE
According to this post you'll need to set up your own runner.
You'll find more information regarding building Android Apps on the same post.
I'm using this docker image to run android build on
gitlab-ci
Update:
Moved to Gitlab registry
Full Guide can check in this Gitlab Repository: https://gitlab.com/showcheap/android-ci
If your Target SDK and Build Tools version are not listed, please make a pull request or fork my repo then make your custom target and build version.