Interview Prep/Azure/Azure DevOps, Bicep and Terraform

Compare variables, variable groups, runtime parameters and secrets in Azure Pipelines.

AdvancedConceptAzure DevOps, Bicep and Terraform
Answer
  • Variables: $(name) macro, ${{ variables.name }} compile-time, $[ variables.name ] runtime expression. Can be set from a script: echo "##vso[task.setvariable variable=tag;isOutput=true]v1".
  • Variable groups: shared across pipelines in Library; can be linked to Key Vault so secrets are fetched at runtime.
  • Parameters: typed, evaluated at compile time, show up as inputs at queue time; they can't change during the run.
  • Secrets: masked in logs, not exposed to scripts as env vars unless mapped explicitly (env: { DB_PASS: $(dbPass) }), and not available to fork PR builds.
Azure All Azure questions Roadmap: AKS & Azure DevOps

More on Azure DevOps, Bicep and Terraform