azure-deployment-preflightlisted
Install: claude install-skill eric-sabe/engsys
# Azure Deployment Preflight
Validate Bicep/ARM deployments locally and clear blocking state *before* you deploy,
so CI doesn't discover what you could have caught. Supports both `az` CLI and `azd`
workflows. Continue through all steps even if one fails — capture every issue, then fix
them in a batch.
> Discipline: **batch your fixes.** Each push triggers a ~15-30 min CI run. Read the
> entire failing module, reason about *all* potential issues, fix them all, push once.
> One CI run per problem cluster, not one per error message.
## When to use
- Before deploying infrastructure to Azure (`az deployment`, `azd up`, `azd provision`).
- When preparing or reviewing Bicep files.
- To preview what a deployment will change (what-if).
- To verify permissions are sufficient.
- After a failed deployment left ARM in a blocking state.
## Step 1 — Detect project type & locate templates
- **azd project:** `azure.yaml` at root → use the **azd workflow**. Bicep usually under
`infra/`. Otherwise use the **`az` CLI workflow**.
- **Locate `.bicep` files** (common: `infra/`, `infrastructure/`, `deploy/`, root) and
the matching parameter file per template: `<name>.bicepparam` (preferred) or
`<name>.parameters.json`.
- Determine the **deployment scope** from `targetScope` in the template
(`resourceGroup` default / `subscription` / `managementGroup` / `tenant`) — it picks
the validate/what-if command in Step 3.
- Confirm context: `az account show` (subscription), resource group, loc