https://github.com/will8ug/learn-terraform-azure
https://github.com/will8ug/learn-terraform-azure
Last synced: 10 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/will8ug/learn-terraform-azure
- Owner: will8ug
- License: bsd-2-clause
- Created: 2024-01-16T09:58:20.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-07-09T13:00:43.000Z (almost 2 years ago)
- Last Synced: 2025-01-19T18:17:00.168Z (over 1 year ago)
- Language: HCL
- Size: 12.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# learn-terraform-azure
[](https://github.com/azure-pocs/learn-terraform-azure/actions/workflows/terraform.yml)
Practices of this guide: [Get Started - Azure](https://developer.hashicorp.com/terraform/tutorials/azure-get-started).
Relevant commands of this repository:
```shell
az login
az account set --subscription ""
az ad sp create-for-rbac --role="Contributor" --scopes="/subscriptions/"
export ARM_CLIENT_ID=""
export ARM_CLIENT_SECRET=""
export ARM_SUBSCRIPTION_ID=""
export ARM_TENANT_ID=""
terraform init
terraform fmt
terraform validate
terraform apply
terraform show
terraform state list
terraform state
terraform state pull azurerm_resource_group.rg
terraform destroy
terraform apply -var "resource_group_name=myNewResourceGroupName"
terraform output resource_group_id
#### Terraform Cloud ####
terraform login
terraform init
```