Installation¶
Requirements¶
- Python 3.8+: python.org
- Azure CLI: installation guide
- Terraform: installation guide
You also need an Azure subscription with an Entra ID tenant. Creating an Azure subscription provides both.
Note
BadZure uses only Entra ID Free tier features, so running it adds no licensing cost. Azure resources it creates (virtual machines, function apps, and the like) incur standard compute charges until you destroy the lab.
Azure CLI and Terraform are required only to build, show, destroy, or plan a lab against a real tenant. Authoring, check, and report run offline with Python alone.
Install¶
Clone the repository:
Create a virtual environment and install dependencies:
Configure the tenant¶
BadZure reads your tenant identifiers from environment variables or from the tenant: block of a configuration file. Copy the example environment file and fill it in:
Set your tenant ID, domain, and subscription ID in .env. A config whose tenant: values are null falls back to these variables.
Authenticate to Azure¶
Building a lab requires Global Administrator in Entra ID and the Owner role on the subscription you will be working on. Using a dedicated service principal is recommended.
Verify the install¶
Confirm the CLI runs and list the commands:
check and report need no Azure login, so you can verify the offline path immediately against a bundled example:
A reachable verdict confirms the install. Continue with Your First Lab.