3

I am new to Azure DevOps and would like to use Environments in my Azure DevOps pipeline. I have seen examples online on regarding how to configure Environments in the yml file (Azure pipeliens.yml) if you are using the yaml editor. However, I am using the classic editor and I am not sure how to integrate the use of Environments into the pipeline or what task should I be editing. I would greatly appreciate any help or sharing of knowledge, thank you!

The following is my current pipeline in the classic editor:

enter image description here

These are examples I seen online where they are able to make use of environment in the pipelines yaml editor

enter image description here enter image description here

Richard Rodjues
  • 207
  • 1
  • 6
  • 23

1 Answers1

5

You can't. They are designed to work with YAML pipelines. Please check this topic on developer community. There is comparison between deployment group and environment. In fact Environment are kind of replacement of deployment group.

Krzysztof Madej
  • 32,704
  • 10
  • 78
  • 107
  • 3
    So, let me see if I understood this properly: a) We can't make use of environments when using the classic editor; b) We can't make use of deployment groups when using YAML; c) We can't create release pipelines using YAML. Thus we can't have a centralised place, either environments or deployment groups, with all the deployment environments, since I am using a YAML CICD pipeline for DEV environment, and release pipelines for the remaining environments. Or am I missing something? – ccoutinho Mar 07 '21 at 15:22
  • 1
    When you create environment, it will create shadow deployment group on the project-collection level named 'environment...". You can then associate the shadow deployment group with project again and use the same agents either through YAML pipeline by deploying to environment, or through Classic pipeline by deploying to Deployment group. – Danielson Jan 26 '23 at 12:48