You could leave the Automatic triggering suppressed and write a tool to scan your GIT repo looking for new branches and trigger the build via an API call when a new branch is found. Sounds like you might need such a tool anyway so that developers could schedule builds.
On Thursday, September 17, 2020 at 12:59:27 AM UTC-4 [email protected] wrote: > 1. I have a multibranch pipeline job that takes 30min to run, has a lot of > branches, and my company is still at the earlier stages of devops > transformation, so with our current infrastructure we do not want to > trigger a build every commit. > > 2. Our job pipeline uses parameters heavily, so I would also like to > automatically build each branch on branch creation/detection. > > How do I achieve the above 2 requirements? > > Using git scm/plugin/branchsource, if I set (or clear) "Suppress Automatic > SCM triggering", I get only one of the two requirements fulfilled: setting > it suppresses ALL automatic triggering, not providing 2. Clearing it > satisfies 2, automatically triggering a build on branch discovery, but also > builds every commit which we don't want. > > In my research I have found the basic branch build strategies plugin > <https://github.com/jenkinsci/basic-branch-build-strategies-plugin/blob/master/docs/user.adoc>, > > and while it provides some great sophisticated control over what branches > build when, in terms of ensuring the job is built on branch creation, it > seems to only provide added suppression. > > Any suggestions would be welcome. Thanks. > -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/ac468efa-99d3-458e-9114-3800ac5484d5n%40googlegroups.com.
