Add a second stage to functions.

This commit is contained in:
Manuele Simi 2019-09-01 22:34:58 -04:00
parent 5366918b57
commit d2f0a1d414
1 changed files with 17 additions and 0 deletions

View File

@ -1,3 +1,15 @@
import groovy.json.JsonSlurper
//locate where this jenkinsfile is
String releaseURL = "https://code-repo.d4science.org/gCubeCI/gCubeRelease/raw/branch/feature/17273/releases/gcube-${params.gCube_release_number}.json"
//check and parse the release file
println "Querying ${releaseURL}"
def text = releaseURL.toURL().getText()
def gcubeJSON = new JsonSlurper().parseText(text)
//check that the release number parameter is the one expected
assert gcubeJSON["gCube.version"] == params.gCube_release_number : "Release versions do not match!"
pipeline {
agent any
stages {
@ -6,6 +18,11 @@ pipeline {
buildComponents items: ("a".."f").collect { "Stage ${it}" }
}
}
stage('build2') {
steps {
buildComponents items: ("g".."fp").collect { "Stage ${it}" }
}
}
}
}