Physical Address
304 North Cardinal St.
Dorchester Center, MA 02124
Physical Address
304 North Cardinal St.
Dorchester Center, MA 02124
If you are using the git branching strategy, in your development, you probably have these three branches that are connected to the following environments.
To choose the group variable we use the ‘if else’ statement. so the pipeline will be like…
variables:
- ${{ if eq(variables['Build.SourceBranchName'], 'develop') }}:
- group: 'gr_dev_app'
- ${{ elseif eq(variables['Build.SourceBranchName'], 'stage') }}:
- group: 'gr_test_app'
- ${{ elseif eq(variables['Build.SourceBranchName'], 'main') }}:
- group: 'gr_prod_app'
Add your variable group name in “- group” based on the environment.
Dont forget the triggers to add
trigger:
branches:
include:
- develop
- stage
- main