Here is my Jenkins pipeline I'm trying to execute. I follow this tutorial :
pipeline {
agent any
stages {
stage('one') {
parallel "first" : {
echo "hello"
},
"second": {
echo "world"
}
}
stage('two') {
parallel "first" : {
echo "hello"
},
"second": {
echo "world"
}
}
}
}
But the operation fails followed by a message.
org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
WorkflowScript: 4: Unknown stage section "parallel". Starting with version 0.5, steps in a stage must be in a steps block. @ line 4, column 9.
stage('one') {
^
WorkflowScript: 12: Unknown stage section "parallel". Starting with version 0.5, steps in a stage must be in a steps block. @ line 12, column 9.
stage('two') {
^
WorkflowScript: 4: Nothing to execute within stage "one" @ line 4, column 9.
stage('one') {
^
WorkflowScript: 12: Nothing to execute within stage "two" @ line 12, column 9.
stage('two') {
^
4 errors
Can someone please help me why this fails.
source
share