Bicep is a domain-specific language that transpiles to ARM JSON. Modules allow you to decompose large deployments into reusable, composable units — with full type checking, IntelliSense, and clean syntax.
CI/CD pipeline for Bicep modules with linting, what-if preview, and gated deployment.
Decorate password parameters with @secure(). Bicep will refuse to display the value in logs and will not store it in deployment history. Never store secrets as plain strings.
Bicep supports resourceGroup (default), subscription, managementGroup, and tenant scopes. Use targetScope = 'subscription' for policy assignments and role definitions.
Microsoft publishes Azure Verified Modules (AVM) on the Bicep public registry (br/public:avm/...). These are production-grade, regularly audited modules — prefer them over writing from scratch.
Use [for item in array: { ... }] to create multiple resources from an array of inputs — equivalent to Terraform's for_each. Supports integer ranges too.
Reference a resource that already exists (not created by this template) using existing keyword: resource vnet 'Microsoft.Network/virtualNetworks@2024-01-01' existing = { name: vnetName }.
Bicep is ~4x less verbose than ARM JSON. Complex ARM templates with 500 lines collapse to ~120 lines of Bicep. Bicep is Microsoft-recommended for all new Azure IaC.
Sign in to share your feedback and join the discussion.