Reputation: 77
Does anyone know how to create a remote repo that pulls packages from https://services.gradle.org/distributions/ ?
This post seems to indicate it's possible, but I haven't had any luck.
This post refers to a video with some instructions, but those don't appear to apply to the version we're on (v7.15).
I suspect I probably need a custom layout, but the file names don't seem to play nicely with the parts Artifactory is expecting.
and set this in the gradle-wrapper.properties:
distributionUrl=https://<server_name>:443/artifactory/gradle-dist/distributions/gradle-6.8-bin.zip
But it does not work. I'm not able to browse the repo in the Artifactory website nor can I execute the build.
Upvotes: 3
Views: 1657
Reputation: 6033
To use Artifactory as a source for Gradle distributions, do the following:
gradle wrapper --gradle-distribution-url=<artifactory-url>/gradle-dist/gradle-5.6.4-bin.zip
If authentication is needed, you can add username and password as system properties when running the Gradle commands:
./gradlew --version -Dgradle.wrapperUser=<artifactory-username> -Dgradle.wrapperPassword=<artifactory-password>
Read more:
Upvotes: 2