0

I have created a azure devops release pipeline. I am using this pipeline to install some prerequisites on server for an application. While installing one of the prerequisites, I have a task (powershell script) which needs ChannelPrefix variable value. I want to set it at runtime because that will depend on environment type for which I am building server.

At the moment I am unable to read the azure devops variable value the way I want.

enter image description here

enter image description here

enter image description here

5
  • If you need to pass environment variables from one script to another, you can assign variables by printing / echoing text in a certain format. For example: echo "##vso[task.setvariable variable=one]secondValue" -- see learn.microsoft.com/en-us/azure/devops/pipelines/process/… Commented Sep 1, 2023 at 13:01
  • Hi James, Thanks for your reply. I am not using environment variable. Its custom defined variable that I am using. Also I am passing not passing its value between multiple scripts. It is just a single script to which I want to pass the value at runtime. Commented Sep 1, 2023 at 13:16
  • Did you link that variable group to release/build? Commented Sep 1, 2023 at 14:08
  • Yes I have linked it. Its just I am using nested thing to read value of variable at runtime Commented Sep 1, 2023 at 14:24
  • Nested variables are not yet supported in Azure pipelines, see this SO thread Commented Sep 3, 2023 at 19:16

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.