Azure Export for Terraform is a command-line utility designed to bring existing Microsoft Azure infrastructure under Terraform management. It discovers deployed Azure resources and identifies their corresponding Terraform resource types. The tool automatically generates HashiCorp Configuration Language (HCL) files, reducing the need to write infrastructure definitions manually. It supports exporting individual resources, entire resource groups, and resources matching Azure Resource Graph queries. Users can generate Terraform state files alongside configuration files to facilitate infrastructure migration. It provides interactive and automated workflows for different deployment scenarios. The utility helps DevOps teams adopt infrastructure as code without recreating existing cloud resources.
Features
- Automatic generation of Terraform HCL configurations from existing Azure infrastructure
- Resource discovery and mapping between Azure and Terraform resource types
- Export support for individual resources, resource groups, and custom queries
- Automatic Terraform state generation for existing cloud resources
- Interactive and non-interactive modes for flexible infrastructure migration
- Cross-platform command-line interface for Windows, Linux, and macOS