Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Allow promotion of job in Jenkins pipeline

I have a Jenkins pipeline which is responsible for about 5 stages (build and several different tests). I'm migrating from Jenkins 1.XX (with no pipelines) to Jenkins 2 and I'd like to replicate my process as closely as possible. The pipeline job I have set up on J2 handles everything exactly the same except it's using a JenkinsFile. The only issue is that the pipeline plugin does not appear to support Promotion of particular builds like you can do with Freestyle Jobs. Has anyone found a way around this?

like image 817
user3270760 Avatar asked Feb 15 '17 18:02

user3270760


People also ask

How do you promote a build in Jenkins pipeline?

To do this, you can create a new job, adding a "Copy artifacts from another job" (available through Copy Artifact plugin") for each item you want to aggregate. To get a certain promotion, select "Use permalink" in the copy artifact step, then your promoted build should show up in the list of items to copy.

How do I promote a specific build number from another job in Jenkins?

Here is how to setup the promotion on build job: You will need these plugins: Parameterized Trigger Plugin, Promoted Builds Plugin. You will also need to setup default Archive the Artifacts post-build action on this build job. Check mark Promote builds when. Define Name "Deploy to DEV"

What is promotion pipeline?

Promotion pipelines are composed by a set of related CI jobs that are executed for each supported OpenStack release to test the content of a specific RDO repository.

What is promoting a build?

Build Promotion allows you to change the status of a build, optionally moving or copying the build's artifacts and its dependencies to a target repository, and setting properties on the promoted artifacts.


1 Answers

Seems like Promoted Builds Plugin doesn't support pipelines yet. If you check the issue there is also some good pros and cons about supporting it for pipelines.

like image 189
Jon S Avatar answered Sep 24 '22 06:09

Jon S