parallel: 并行执行多个stage
failFast true: 只要有一个stage不通过,就中止运行
格式如下:任务1和任务2会同时运行,有一个任务失败就会中止运行
pipeline {
agent {
node { label 'master' }
}
environment{
}
stages {
stage ('git checkout') {
steps {
}
}
stage ('Sync Code'){
failFast true
parallel {
stage ('任务1'){
steps {
}
}
stage ('任务2'){
steps {
}
}
}
}
}
}