2
votes

I'm looking for a tool that we allow me to script a Jenkins build pipeline made up of a series of individual build jobs.

Is the Jenkins Workflow plugin capable of doing this?

Ideally I would use the groovy script to define which jobs needs to run, in what order, which ones can run in parallel etc but leave the details of exactly what each job does to the job itself.

So I guess my question boils down to,

  1. Can you trigger build jobs from a workflow script?
  2. Can you define what should happen in parallel from the script?
2

2 Answers

1
votes

Yes, you can use the parallel and build steps for this purpose.

There is no need for the Parameterized Trigger plugin unless you need to start a Workflow build with parameters from a traditional project, which does not sound like your use case.

0
votes

Yes Jenkins workflow plugin is used for creating deployment pipelines. Individual workflow plugin can not do this job. You can also used parameterized trigger plugin which will trigger your jobs and by one. Suppose you have job A,B,C and D. You want to trigger Job A and it will trigger your other jobs sequentially.

A->B->C->D

With workflow you can see the complete workflow how the jobs are triggered and its status.

To trigger your first job which is job A, you can use Jenkins API's. We write git pre-commit hooks to trigger our CI cycle.