Prerequisites
Azure CLI initialization and subscription setup required before Terraform deployments.
[!NOTE] Part of the Deployment Guide. Return there for navigation and deployment order.
📜 Scripts
| Script | Purpose |
|---|---|
az-sub-init.sh | Azure login and ARM_SUBSCRIPTION_ID export |
register-azure-providers.sh | Register required Azure resource providers |
🚀 Usage
Source the initialization script to set ARM_SUBSCRIPTION_ID for Terraform:
source az-sub-init.sh
For a specific tenant:
source az-sub-init.sh --tenant your-tenant.onmicrosoft.com
For new Azure subscriptions or subscriptions that haven't deployed AKS, AzureML, or similar resources, register the required providers:
./register-azure-providers.sh
The script reads providers from robotics-azure-resource-providers.txt and waits for registration to complete. This is a one-time operation per subscription.
⚙️ What It Does
az-sub-init.sh
- Checks for existing Azure CLI session
- Prompts for login if needed (optionally with tenant)
- Exports
ARM_SUBSCRIPTION_IDto current shell
The subscription ID is required by Terraform's Azure provider when not running in a managed identity context.
register-azure-providers.sh
- Reads required providers from
robotics-azure-resource-providers.txt - Checks current registration state via Azure CLI
- Registers unregistered providers
- Polls until all providers reach
Registeredstate
➡️ Next Step
After initialization, proceed to Infrastructure Deployment to deploy Azure resources.
🤖 Crafted with precision by ✨Copilot following brilliant human instruction, then carefully refined by our team of discerning human reviewers.