This lab is created to demonstrate the implementation of Azure resources with Terraform code. Links to lab scenerio and the details can be found in each sub-directory of this repository (under Contents).
- azure CLI is required for terraform to interact with azure resources For detailed explanation to install and login with azure cli https://learn.microsoft.com/en-us/cli/azure/install-azure-cli
- Install and configure terraform https://developer.hashicorp.com/terraform/install
1 - Connect virtual networks with virtual network peering
2 - Create and associate service endpoint policies
3 - Restrict network access to PaaS resources with virtual network service endpoints
terraform init -upgrade
terraform fmt && terraform validate
terraform plan -out main.tfplan
terraform apply main.tfplan # or terraform apply --auto-approve
terraform state list
terraform state show <resource> # detailed list on the resource
terraform plan -destroy -out main.destroy.tfplan
terraform apply main.destroy.tfplan # or terraform destroy
terraform -install-autocomplete # for autocompletion