Azure / devops-governance

Example end-to-end Governance Model from CI/CD to Azure Resource Manager. Use this project to deploy example AAD, ARM and Azure DevOps resources to learn about e2e RBAC.
MIT License
189 stars 93 forks source link

Update CI/CD pipelines to support multiple environments #27

Closed julie-ng closed 3 years ago

julie-ng commented 3 years ago

Now that the project is configured to target two environments (production and dev), we need to update the CI/CD pipelines accordingly.

julie-ng commented 3 years ago

Pull Request Target Branch Variable

System.PullRequest.TargetBranch is only available if there is a git branch protection policy applied to that target branch

I read the Predefined Variables documentation too quickly 🤦‍♀️

System.PullRequest.TargetBranch The branch that is the target of a pull request. For example: refs/heads/master when your repository is in Azure Repos and master when your repository is in GitHub. This variable is initialized only if the build ran because of a Git PR affected by a branch policy. This variable is only available in a YAML pipeline if the PR is affected by a branch policy.

azure-pipelines[bot] commented 3 years ago

⚠️  Configuration Drift Detected

Source Version: b8c209e48cb7c3db8b641dc930e21c91e0de805c

Approving this Pull Request may result in destructive changes to your Azure resources. Please review the terraform plan output diff at Azure Pipelines Build Result Page.

Proceed with caution!

azure-pipelines[bot] commented 3 years ago

🟢  No configuration drift detected

Source Version: 3c493a1d252d75229d10ea8f1e8c5e59b4ebace1

azure-pipelines[bot] commented 3 years ago

⚠️  Configuration Drift Detected

Source Version: fcc3ef819d801f74c566b77f865603edc7f6e5a9

Approving this Pull Request may result in destructive changes to your Azure resources. Please review the terraform plan output diff at Azure Pipelines Build Result Page.

Proceed with caution!

azure-pipelines[bot] commented 3 years ago

⚠️  Configuration Drift Detected (OR State File Locked)

Source Version: 0198626d9025f57d4834d7427bf1ec487b45d359

Approving this Pull Request may result in destructive changes to your Azure resources. Please review the terraform plan output diff at Azure Pipelines Build Result Page.

Proceed with caution!

azure-pipelines[bot] commented 3 years ago

🟢  No configuration drift detected

Source Version: 3a704399f1d54765f2ec3e0a44f6e6e1dde67d41