1

I have two pipelines on azure devops that do the following:

BUILD PIPELINE

  • Asks the user for the desire branch name and ticket id (from our ticketing system). Using two "settable at queue time" variables.
  • Gets the files from the specified branch name, builds the project and generate the artifacts that are later use by the RELEASE pipeline

RELEASE PIPELINE

This release pipeline is being triggered by the completion of the BUILD pipeline specified before. This pipeline completes the following tasks:

  • Creates new app service slot using an Azure CLI command task. In this task I need the ticket id, in order to create the slot with the corresponding ticket id as its name

  • Deploy the application to the created app service slot

I haven't found a way to pass to the RELEASE pipeline the ticket id the user entered when running the BUILD pipeline that triggered this RELEASE.

  • Does this answer your question? [VSTS : Can I access the Build variables from Release definition?](https://stackoverflow.com/questions/50905024/vsts-can-i-access-the-build-variables-from-release-definition) – Shayki Abramczyk Mar 31 '20 at 07:33

1 Answers1

1

Unfortunately, there's no such a build-in function in Azure DevOps. While thanks to Martin Hinshelwood, we had an extension- Variable Tools for Azure DevOps Services to achieve the goal.

As you can see in the extension's doc, add a Variable Save Task in your build pipeline and a Variable Load Task in your release pipeline. After these two tasks, the variables are fully passed to your release.

Check below as reference:

enter image description here

enter image description here

Yang Shen - MSFT
  • 1,136
  • 1
  • 7
  • 9
  • Thanks Yang; this were really helpful. It is wroking as expected. – JeanCarloDeCastro Mar 31 '20 at 13:32
  • Although this is a very useful extension, the lack of proper documentation is quite infuriating. Do we need to create a Variable explicitly in the Variables section of the build and release pipelines before that can be accessed by the Load and Save tasks? – Ajay Meda Oct 11 '22 at 21:19