1

We do have this configuration in our GUI based Jenkins project, trying to convert it to Jenkins pipeline, couldn't find how to add precurse-build as dependent build as shown in red below.

Gerrit Trigger Plugin options

I added below below pipeline code to trigger the build whenrun_job is added as gerrit comment, and it works good, would anyone please show me how to add Other jobs on which this job depends to this?

pipeline { triggers { gerrit dynamicTriggerConfiguration: 'true', triggerConfigURL: 'https://some/url/path/trigger.txt', serverName: 'gerrit-server', triggerOnEvents: [ commentAddedContains('^run_job$') ] } stages { ... ... 

1 Answer 1

1

The "correct" way to determine the names for Pipeline step parameters is to use the Pipeline Snippet generator in the web UI:

https://www.jenkins.io/doc/book/pipeline/getting-started/#snippet-generator

However, based on browsing the source code, I am guessing the name of the parameter you are looking for is dependencyJobsNames.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.