-
Bug
-
Resolution: Fixed
-
Critical
-
None
The plugin injects the public Maven repositories. When running a build behind a firewall with local Maven repository this will cause the build to take a very long time (30-60min).
I had to remove the repository URLs after the plugin was loaded.
It would be better if the repository URLs are documented in the Wiki but not injected by default.
Workaround:
// remove external repositories that were injected by JPI plugin - we only use our local Nexus
repositories {
all { repo ->
if (repo.url.toString().contains("http://repo1.maven.org/") || repo.url.toString().contains("http://maven.jenkins-ci.org/")) {
logger.warn "Repository ${repo.url} REMOVED"
remove repo
}
}
}
I opened a pull request to add a configureRepositories option to be able to skip configuration of repositories:
https://github.com/jenkinsci/gradle-jpi-plugin/pull/47