'How can we trigger a parameterised jenkins release job manually (it takes Pull request ID) only if Pull request build job was successful?
I have setup a jenkins pipeline job which gets triggered whenever a new Pull request arrives on my github repository main branch (this job builds and run tests for that specific PR).
Now, I have created another parameterised jenkins pipeline job which takes Pull request id and release the artifacts to artifactory. I want that upon triggering this parameterized job manually, it should fail if the 1st jenkins job configured on the Pull request has failed. Else, if 1st job was successful, then, release pipeline can continue its work.
Is there a way to do this?
PS: I can add entire content of that first jenkins job in a stage before release pipeline stage, but that would make it time consuming.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|