Forum Discussion
Quest198z
Nov 15, 2023Copper Contributor
Azure DevOps Org Patterns for separated teams
Are there any patterns or documents around AzDo Setups where there is a central IaC pipeline and then sub teams deploying application related or platform related resources in an Azure Environment with Private endpoints/Services.
Teams would need to get Infra changes from central pipeline. What are the options to trigger jobs from another repo and how would you secure the service connection to run only in specific projects with specific pipelines only? Teams should only be able to call the infra pipeline to refresh? Is this even possible?
9 Replies
Sort By
- Quest198zCopper ContributorAt the current moment, due to our internal structure, teams can not create resources outside of designated resource groups.
Again are there any patterns for organizations that still have silos due to compliance reasons and when using azure with private endpoints. IF you create resources with private endpoints they must touch networking resource groups and then touch a centralized private dns which is most likely outside of the resource group for the application. I have not seen alot of guidance in this scenario. This ensures that applications have a small blast radius. - Quest198zCopper ContributorIt is not just common infra. Its any infra in general.
company Org
Infra Project in devops that has repos of code
pipelines for Azure Infra deployments
business unit X -> code -> deploy to web apps or functions
- j_folberth
Microsoft
Would need to know more detail to better answer this question. When we say central IaC pipeline are referring to a central repository or a pipeline that deploys an entire subscription(s) resources? Also is this around a module based deployment (Bicep, ARM, Terraform?)- Quest198zCopper ContributorSo there is a central team that manages IaC deployments for All Azure resources. Due to our structure in the organization, devs can modify or push code to the resources. They will have their own AzDo Projects. The Central Team pushes the Infra in one project and then once completed, dev teams can go about deploying to the resource. The challenge I have is how can the devs call that Infra pipeline or are there ways to connect to two different pipelines if they are in different AzDo Projects. My question can their be a way to merge the two or share service connections with proper controls in AzDo? In regards to the ARM/Bicep with template specs to version a collection of resources for a product catalog. We are looking at Terraform now because of state or consistency issues, but I do know that deployment stacks for ARM is coming out. In any case, I'm looking for patterns for when an org has this type of structure.
- j_folberth
Microsoft
It still is not clear when referring to "infra in one project'" is this a single repo w/ all the infrastructure or a repo per app infrastructure?
There is a way to chain pipelines together; however, I feel this will cause overhead and run some risk as a good practice is typically have a single multi-stage pipeline that goes to DEV, STG, then PRD as opposed to three separate pipelines with one for each environment.
I THINK what you would be looking at is something like a YAML repository resource block that will copy the source infrastructure from the repository and produce it as an artifact to the development team's pipelines. This will limit their control/ability to update the Infra; however, have a copy associated with their app code pipeline and deployed with it. This will really help if ever needing to rollback and prevent any environment drift.
To achieve this in the developer pipeline the IaC project/repository would be declared as a resource block https://learn.microsoft.com/en-us/azure/devops/pipelines/process/resources?view=azure-devops&tabs=schema#define-a-pipelines-resource
Then will want to publish the IaC to the developer pipeline https://learn.microsoft.com/en-us/azure/devops/pipelines/artifacts/pipeline-artifacts?view=azure-devops&tabs=yaml
This will also have the benefit of consolidating pipelines and ensuring the IaC components are deployed via a Service Connection. The developers will still not be able to maintain the IaC; however, have the ability to control deployment of it.
Alternatively, since you are in ARM/Bicep would recommend at least evaluating the use of Bicep Registries https://learn.microsoft.com/en-us/azure/azure-resource-manager/bicep/private-module-registry?tabs=azure-powershell to centralize your templates for mass consumption.