aboutsummaryrefslogtreecommitdiff
path: root/build.gradle
diff options
context:
space:
mode:
authorOlaf Flebbe <of@ofleb.be>2015-12-05 18:54:29 +0100
committerOlaf Flebbe <of@ofleb.be>2015-12-05 18:54:29 +0100
commit152bebe1d8b9a5f97010defe2a669290d4621508 (patch)
tree7227cfbcc164eb10554ffb65e8fded56eeb9059e /build.gradle
parenta03c599076218981c8bfce3d64fb2df579d8d305 (diff)
Revert "BIGTOP-2081: Implement a nexus docker container for CI"
This reverts commit 775ab7f544ae17ac97b45e6a96937494b5ea8a43.
Diffstat (limited to 'build.gradle')
-rw-r--r--build.gradle46
1 files changed, 0 insertions, 46 deletions
diff --git a/build.gradle b/build.gradle
index 047abc35..2a480560 100644
--- a/build.gradle
+++ b/build.gradle
@@ -310,52 +310,6 @@ def artifactToInstall = {
}
}
-def generate_nexus_tasks = { name, url, snapshot ->
- task "configure-nexus-${name}"(type: Exec) {
- def req = [ data : [ id: name, name: name, repoType: "proxy", repoPolicy : snapshot, browseable: true, "indexable": true, "notFoundCacheTTL": 1440,
- "artifactMaxAge": 1440, "metadataMaxAge": 1440, "itemMaxAge": 1440, "provider": "maven2",
- "providerRole": "org.sonatype.nexus.proxy.repository.Repository", "downloadRemoteIndexes": true,
- "autoBlockActive": true, "fileTypeValidation": true, "exposed": true, "checksumPolicy": "WARN",
- "remoteStorage": ["remoteStorageUrl": url, "authentication": null,
- "connectionSettings": null]]]
- def root = new groovy.json.JsonBuilder(req)
- def p = root.toString()
- File.createTempFile("temp",".tmp").with {
- deleteOnExit()
-
- write root.toString()
-
- workingDir '.'
- commandLine "curl", "-o", "/dev/null", "-X", "POST", "-d", "@$absolutePath", "--header", "Content-Type: application/json", "-u", "admin:admin123", "http://localhost:8081/service/local/repositories"
- }
- }
-}
-
-def repos = [ [ "name": "conjars", "url" : "http://conjars.org", 'snapshot':'RELEASE'],
- [ "name": "repository.jboss.org", "url": "http://repository.jboss.org/nexus/content/groups/public/", 'snapshot': 'RELEASE'],
- [ "name": "apache.snapshots.https", "url": "https://repository.apache.org/content/repositories/snapshots", "snapshot": "SNAPSHOT"],
- [ "name": "apache.snapshots", "url": "https://repository.apache.org/content/repositories/snapshots", "snapshot": "SNAPSHOT"]]
-
-repos.each { r->
- generate_nexus_tasks( r.name, r.url, r.snapshot)
-}
-
-task "configure-nexus"(dependsOn: tasks.findAll { alltask -> alltask.name.startsWith("configure-nexus-")}*.name,
- description: "configure all repos") {
- def m2Dir = System.getProperty("user.home") + "/.m2"
- mkdir(m2Dir)
- def writer = new File(m2Dir + "/settings.xml")
- def writeMirrorLine = { name ->
- writer.append("<mirror><name>$name</name><url>http://localhost:8081/content/repositories/$name/</url><mirrorOf>$name</mirrorOf></mirror>")
- }
- writer.text = "<settings><mirrors>"
- writeMirrorLine( "central")
- repos.each{ r->
- writeMirrorLine( r.name)
- }
- writer.append("</mirrors></settings>")
-}
-
task "gen-gradle-home"(type:Exec,
description: 'Pre-load gradle home as cache for bigtop/slaves images',
group: DOCKERBUILD_GROUP) {