Interview Prep/Azure/CI/CD and IaC

You need to deploy infrastructure and application in one pipeline but with separate approvals.

IntermediateScenarioCI/CD and IaC
Answer

Situation read → Separate stages, environments and identities.

What I'd do →

  1. Stage infra-plan (Reader identity), output plan artifact
  2. Stage infra-apply targeting environment infra-prod with platform team approval (Contributor identity)
  3. Stage app-deploy targeting environment shop-prod with app team approval (namespace-scoped identity)
  4. Skip infra-apply when the plan has no changes (set an output variable from terraform plan -detailed-exitcode)

Why → Different owners approve different risks, and each stage has only the rights it needs.

Interview tip → Conditional infra stages keep pipelines fast.

Azure All Azure questions Roadmap: AKS & Azure DevOps

More on CI/CD and IaC