How to build a pipeline of jobs in Jenkins?

一世执手 提交于 2019-12-04 09:48:07

Perhaps you could use the Parametrized Trigger Plugin?

Using the plugin you can set the trigger as a build step in your "Pipeline" Job. There is a checkbox "Block until triggered job is finished", which you need to activate. You could simply configure your three jobs to be triggered this way, and the triggering would only occur if you run this new Pipeline Job, so running the other jobs without triggering anything would work fine.

This should be exactly what you need.

Don't know if you've found your answer yet, but for others who are curious:

You can create another job build_all, and then have each of the other builds triggered as build steps.

The setup you'd want would look like this for build_all, with each build step being "Trigger/Call builds on other projects"

  • Build Step 1 : all-commons_RELEASE
  • Build Step 2 : web-A_RELEASE
  • Build Step 3 : web-B_RELEASE
  • Build Step 4 : web-C_RELEASE

Make sure you check the "Block until the triggered projects finish their builds" option to ensure the builds happen sequentially.

Try this

Build Flow plugin

you can sequentially run or build your job like this :

build("job1")
build("job2")
.
.
build("job-n")
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!