How to pass parameters in downstream jenkins jobs

I got a question how to pass parameter in trailing jobs. Jenkins 2.0 provides option to use Jenkinsfile.

  1. Takes in parameter “Task_Name”
  2. Runs Job-1 and pass in parameter “Task_Name” to it
  3. Upon successful run of Job-1, it will trigger Job-2 and pass in the “Task_Name” parameter
  4. Note that Job-1 and Job-2 are 2 separate Jenkins jobs, and the Jenkinsfile below belongs to the Jenkins job that triggers both Job-1 and Job-2

 

Leave a Reply

Your email address will not be published. Required fields are marked *