Trying to run my Gradle Android project on circleci.com I got the following Warning:
Warning: The build VMs have a memory limit of 4G. Your build hit this limit on one or more containers, and your build results are likely invalid.
The GRADLE_OPTS can be set in the circle.yml file:
machine:
environment:
GRADLE_OPTS: -Xmx512m -XX:MaxPermSize=512m
Allowing you to keep development configs and build configs separate.
Edit:
CircleCi have updated their documentation, this is the recommended config for Android builds:
machine:
environment:
GRADLE_OPTS: '-Dorg.gradle.jvmargs="-Xmx2048m -XX:+HeapDumpOnOutOfMemoryError"'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With