Any update on this one? It works in the UI for regular, non-multibranch pipelines. How would one add this to a Jenkinsfile? I've scoured Google and Stack Overflow and nothing. dmone, anything? Anyone?
Joshua Westmoreland
added a comment - Any update on this one? It works in the UI for regular, non-multibranch pipelines. How would one add this to a Jenkinsfile? I've scoured Google and Stack Overflow and nothing. dmone , anything? Anyone?
Hi jdwntrepid.
If i understand correctly you want to configure the blocking behaviour of pipeline from the Jenkinsfile itself and not only from the UI.
Something like the following:
I understand that this is indeed useful but at this time i don't have time to implement it.
You are welcome to contribute though.
I did a quick google search about Jenkins plugin development and i found this link which is what you probably need to get started plugin-development/pipeline-integration/#defining-symbols
Denis Mone
added a comment - Hi jdwntrepid .
If i understand correctly you want to configure the blocking behaviour of pipeline from the Jenkinsfile itself and not only from the UI.
Something like the following:
pipeline {
agent {
docker {
image 'jdk11'
}
}
options {
// your request
blocksOn {
'another-job' , global: false , checkQueue: false
}
}
stages {
stage( 'stage1' ) {
//...
}
stage( 'stage2' ) {
//...
}
}
}
I understand that this is indeed useful but at this time i don't have time to implement it.
You are welcome to contribute though.
I did a quick google search about Jenkins plugin development and i found this link which is what you probably need to get started
plugin-development/pipeline-integration/#defining-symbols
Any update on this one? It works in the UI for regular, non-multibranch pipelines. How would one add this to a Jenkinsfile? I've scoured Google and Stack Overflow and nothing. dmone, anything? Anyone?