Gradle + Jenkins + Artifactory Maven Repo? Gradle + Jenkins + Artifactory Maven Repo? jenkins jenkins

Gradle + Jenkins + Artifactory Maven Repo?


  • Gradle Artifactory plugins: Gradle can deploy build artifacts and build information directly, without need in CI server by using one of the Artifactory plugins.
    • artifactory plugin works with maven plugin and publishes configurations, generated by maven plugin.
    • artifactory-publish plugin works with maven-publish plugin and publishes publications generated by maven-publish plugin.
  • Jenkins Artifactory plugin works in two modes:
    • Providing a UI to override settings, specified in artifactory or artifactory-publish plugins in Gradle build script.
    • Adding and configuring artifactory plugin to the Gradle script if it is not there.
    • It also provides release management (for both modes).

So, here's what you need to decide:

  • Whether you use one of the Gradle plugins. Our recommendation is - use it (versioned configuration in build script is an advantage comparing to UI-only configuration.
  • Which plugin you want to use -- maven or maven-publish. While the later is still 'incubating', it is much more flexible than the former. Once you know with which maven plugin you want to use, select the appropriate artifactory plugin.
  • You need the Artifactory Jenkins plugin in either way if you want to use the release functionality, just check (or uncheck) the 'Project uses the Artifactory Gradle Plugin' checkbox.