Azure
Clanker supports querying Azure infrastructure using the az CLI. Queries are routed to Azure by an explicit flag or by automatic keyword detection.
Authentication
Azure authentication uses the az CLI login flow.
Setting up authentication
# Interactive login
az login
# Set default subscription
az account set --subscription your-subscription-id
# Verify
az account showConfiguration
Add your Azure subscription ID to ~/.clanker.yaml:
infra:
azure:
subscription_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"Subscription ID resolution order
--azure-subscriptionCLI flaginfra.azure.subscription_idin the config fileAZURE_SUBSCRIPTION_IDenvironment variableAZ_SUBSCRIPTION_IDenvironment variable
Querying Azure
Explicit flag
clanker ask --azure "What virtual machines are running?"Automatic routing
If your question mentions Azure-specific services, Clanker routes to Azure automatically:
clanker ask "List all Azure Container Apps"Supported Services
Clanker queries Azure services through the az CLI. Commonly queried services include:
- Virtual Machines
- Azure Kubernetes Service (AKS)
- Container Apps
- App Service
- Azure SQL
- Blob Storage
- Virtual Networks
- Load Balancers
- Azure Functions
- Key Vault
Maker Pipeline
The maker feature supports Azure infrastructure provisioning:
# Generate a plan
clanker ask --maker --azure "Create a resource group called my-rg in eastus"
# Apply the plan
clanker ask --apply --plan-file plan.json --azure-subscription your-sub-idAzure maker plans require the subscription ID during both generation and execution.
Backend Credentials
For team environments, Azure service principal credentials can be stored and retrieved through the Clanker backend:
clanker credentials store azure
clanker ask --api-key ck_live_abc123 --azure "What VMs are running?"When backend credentials include a service principal (tenant ID, client ID, client secret), Clanker performs an az login --service-principal before executing queries.