trigger pipeline with options

Follow

Comments

5 comments

  • Avatar
    Ian Bridson

    Lee


     


    Pipeline-level Environment Variables can be entered by a user on the  Trigger with Options dialogue (second tab), before triggering.


    Enter following in a pipline config to set a variable up:


    <environmentvariables>


       <variable name="build_required" >Yes</variable>


    <environmentvariables>


     



    I would also like to see this ability at Stage level approval with the user prompted to enter any stage-level environment variables before proceeding


    Ian 



     
  • Avatar
    LeeBenhart

    Thanks Ian, I will give this a try.  It will save me a lot of custom work.

  • Avatar
    LeeBenhart

    Do you know if there is a way to FORCE <Trigger with option> on manual approvals?  Basically, can the default run <Trigger> be disabled?

  • Avatar
    Anush Ramani

    You can have your scripts return with an error code if the required environment variables are not passed. That way, even though the pipeline is triggered, it will only complete if the necessary variables are entered by the user i.e. it will only complete successfully if a user triggers with options and enters the required variables.


    There is currently no way to force a trigger with options, but you can use the above workaround to achieve the same result.

  • Avatar
    LeeBenhart

    Thank you Anush, that is the approach I had decided to use.

Please sign in to leave a comment.