I need to run automated Android builds on a VM that has no access to the outside world.
Unfortunately, when running gradle for the first time to create a build, it starts downloading various packages and also seems to set up some variables/environment that I am not aware of.
I already tried pre-installing the .gradle/ directory at %USERPROFILE%.gradle, with all the zips, pom and jar files, but still there is something missing. This is the error I am now seeing on my VM:
A problem occurred configuring root project ‘player_activity’.
Could not resolve all dependencies for configuration ‘:classpath’.
Could not download gradle.jar (com.android.tools.build:gradle:2.1.2)
Could not get resource ‘https://jcenter.bintray.com/com/android/tools/build/gradle/2.1.2/gradle-2.1.2.jar’.
Could not HEAD ‘https://jcenter.bintray.com/com/android/tools/build/gradle/2.1.2/gradle-2.1.2.jar’.