Implemented changes per review
This commit is contained in:
parent
2c79eb6a23
commit
a8ba805c8b
@ -14,9 +14,11 @@ provider "azurerm" {
|
||||
features {}
|
||||
}
|
||||
|
||||
resource "random_uuid" "uuid" {}
|
||||
resource "random_pet" "rg-name" {
|
||||
prefix = var.resource_group_name_prefix
|
||||
}
|
||||
|
||||
resource "azurerm_resource_group" "rg" {
|
||||
name = "${var.resource_group_name_prefix}-${random_uuid.uuid.result}"
|
||||
name = random_pet.rg-name.id
|
||||
location = var.resource_group_location
|
||||
}
|
||||
|
@ -11,8 +11,8 @@ This template deploys an Azure resource group with a random name beginning with
|
||||
|
||||
| Name | Description |
|
||||
|-|-|
|
||||
| `resource_group_name_prefix` | Prefix of the resource group name that's combined with a random number so name is unique in your Azure subscription. |
|
||||
| `resource_group_location` | The Azure Region to deploy these resources in |
|
||||
| `resource_group_name_prefix` | (Optional) Prefix of the resource group name that's combined with a random number so name is unique in your Azure subscription. |
|
||||
| `resource_group_location` | (Optional) The Azure Region to deploy these resources in |
|
||||
|
||||
## Example
|
||||
|
||||
|
@ -1,8 +1,9 @@
|
||||
variable "resource_group_name_prefix" {
|
||||
default = "rg"
|
||||
description = "Prefix of the resource group name that's combined with a random number so name is unique in your Azure subscription."
|
||||
description = "Prefix of the resource group name that's combined with a random ID so name is unique in your Azure subscription."
|
||||
}
|
||||
|
||||
variable "resource_group_location" {
|
||||
default = "eastus"
|
||||
description = "Location of the resource group."
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user