naiyu naiyu - 2 months ago 93x
Android Question

Configuring gitlab ci for Android project

I have a '.gitlab-ci.yml' file in my project root:

- ./gradlew assembleRelease
stage: deploy
- android
allow_failure: true

while I push to the master, it will build and is succesed, but I can find any apk file in my project.

This is my log:

running with gitlab-ci-multi-runner 1.4.2 (bcc1794)
Using Shell executor...
Running on userMacBook-Pro.local...
Fetching changes...
Removing .gradle/
Removing app/build/
Removing build/
HEAD is now at 3ae32fc back back
3ae32fc..5312eaa master -> origin/master
Checking out 5312eaaf as master...
$ ./gradlew assembleRelease
Starting a new Gradle Daemon for this build (subsequent builds will be faster).
Incremental java compilation is an incubating feature.
:app:preBuild UP-TO-DATE
:app:preReleaseBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:compileReleaseJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
:app:compileReleaseNdk UP-TO-DATE
To run dex in process, the Gradle daemon needs a larger heap.
It currently has approximately 910 MB.
For faster builds, increase the maximum heap size for the Gradle daemon to more than 2048 MB.
To do this set org.gradle.jvmargs=-Xmx2048M in the project
For more information see
:app:processReleaseJavaRes UP-TO-DATE


Total time: 32.012 secs
Build succeeded

My runner executor is
on my Mac OS.

Is there any wrong with my path, or is there has any blog to show this.


The Gitlab CI works like that: you push changes to the server and your local runner make a clone (or a pull) of your latest changes.

The sources will be downloaded in a subfolder of the runner, not in your project. This means that the apk will be in one of these subfolders as well.