Prepare the different options for the builds.
This commit is contained in:
parent
342047ad60
commit
82afb3ecf2
|
@ -1,13 +1,27 @@
|
|||
|
||||
// set the job options according to the Type of build
|
||||
def options = ''
|
||||
if (params.Type == 'SNAPSHOT') {
|
||||
echo "Will configure Maven for SNAPSHOT artifacts"
|
||||
}
|
||||
echo "Will configure Maven for SNAPSHOT artifacts"
|
||||
options = ''
|
||||
maven_local_repo_path = ''
|
||||
maven_settings_file = ''
|
||||
}
|
||||
if (params.Type == 'RELEASE') {
|
||||
echo "Will configure Maven for RELEASE artifacts"
|
||||
echo "Will configure Maven for RELEASE artifacts"
|
||||
options = ''
|
||||
maven_local_repo_path = ''
|
||||
maven_settings_file = ''
|
||||
}
|
||||
|
||||
pipeline {
|
||||
agent any
|
||||
|
||||
|
||||
// environment variables available to the Pipeline
|
||||
environment {
|
||||
JOB_OPTIONS = "${options}"
|
||||
}
|
||||
|
||||
parameters {
|
||||
choice(choices: ['SNAPSHOT', 'RELEASE'],
|
||||
description: 'The type of artifacts the build is expected to generate',
|
||||
|
@ -18,10 +32,10 @@ pipeline {
|
|||
stage('build core components') {
|
||||
steps {
|
||||
withMaven(jdk: 'OpenJDK 8') {
|
||||
build 'maven-parent'
|
||||
build 'gcube-bom'
|
||||
build 'authorization-common-library'
|
||||
build 'gxRest'
|
||||
build 'maven-parent/master'
|
||||
build 'gcube-bom/master'
|
||||
build 'authorization-common-library/master'
|
||||
build 'gxRest/master'
|
||||
}
|
||||
script {
|
||||
echo "Done with core components"
|
||||
|
|
Loading…
Reference in New Issue