blob: be52d0c34f68fa55332a98a54a2350a7bd3d6fbd [file] [log] [blame]
def build = library(
identifier: 'rcptt-pipeline-library@groovy',
retriever: modernSCM(
[
$class: 'GitSCMSource',
remote: 'https://github.com/xored/rcptt.git'
]
)
).org.eclipse.rcptt.jenkins.Build.new(this)
pipeline {
agent {
kubernetes {
label 'rcptt-build-agent-3.5.4'
yaml build.YAML_BUILD_AND_DEPLOY_AGENT
}
}
parameters {
choice(name: 'MODE', choices: ['Release', 'Milestone'], description: 'The deploy mode')
string(name: 'MILESTONE_VERSION', defaultValue: 'MO', description: 'Only for milestone build')
}
stages {
stage('Start Build and Test') {
steps {
script {
if(params.MODE == 'Milestone') {
build.set_milestone(params.MILESTONE_VERSION)
}
build.build_and_test(false)
}
}
}
stage('Deploy') {
steps {
script {
build.deploy(params.MODE, params.MILESTONE_VERSION)
}
}
}
}
post {
always {
script {
build.post_build_actions()
}
}
}
}