Skip to content

Commit

Permalink
added name output (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
jchancellor-ms authored Jun 24, 2024
1 parent 9b7bb6e commit ab9d305
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 14 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ This module implements the AVM version of the Azure Cache for Redis and supporti

The following requirements are needed by this module:

- <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) (>= 1.5.0)
- <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) (~> 1.7)

- <a name="requirement_azapi"></a> [azapi](#requirement\_azapi) (~> 1.13, != 1.13.0)

Expand Down Expand Up @@ -637,6 +637,10 @@ Default:

The following outputs are exported:

### <a name="output_name"></a> [name](#output\_name)

Description: The name of the redis resource

### <a name="output_private_endpoints"></a> [private\_endpoints](#output\_private\_endpoints)

Description: A map of private endpoints. The map key is the supplied input to var.private\_endpoints. The map value is the entire azurerm\_private\_endpoint resource.
Expand Down
14 changes: 7 additions & 7 deletions examples/default/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ This deploys the Azure Cache for Redis module in its simplest form.

```hcl
terraform {
required_version = ">= 1.3.0"
required_version = "~> 1.7"
required_providers {
azurerm = {
source = "hashicorp/azurerm"
Expand Down Expand Up @@ -36,7 +36,7 @@ locals {
# This allows us to randomize the region for the resource group.
module "regions" {
source = "Azure/regions/azurerm"
version = ">= 0.3.0"
version = "~> 0.6"
}
# This allows us to randomize the region for the resource group.
Expand All @@ -49,7 +49,7 @@ resource "random_integer" "region_index" {
# This ensures we have unique CAF compliant names for our resources.
module "naming" {
source = "Azure/naming/azurerm"
version = ">= 0.3.0"
version = "~> 0.4"
}
# This is required for resource modules
Expand Down Expand Up @@ -99,7 +99,7 @@ resource "azurerm_log_analytics_workspace" "this_workspace" {
module "default" {
source = "../../"
# source = "Azure/avm-res-cache-redis/azurerm"
# version = "0.1.0"
# version = "0.1.1"
enable_telemetry = var.enable_telemetry
name = module.naming.redis_cache.name_unique
Expand Down Expand Up @@ -149,7 +149,7 @@ module "default" {

The following requirements are needed by this module:

- <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) (>= 1.3.0)
- <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) (~> 1.7)

- <a name="requirement_azurerm"></a> [azurerm](#requirement\_azurerm) (~> 3.105)

Expand Down Expand Up @@ -212,13 +212,13 @@ Version:

Source: Azure/naming/azurerm

Version: >= 0.3.0
Version: ~> 0.4

### <a name="module_regions"></a> [regions](#module\_regions)

Source: Azure/regions/azurerm

Version: >= 0.3.0
Version: ~> 0.6

<!-- markdownlint-disable-next-line MD041 -->
## Data Collection
Expand Down
8 changes: 4 additions & 4 deletions examples/default/main.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
terraform {
required_version = ">= 1.3.0"
required_version = "~> 1.7"
required_providers {
azurerm = {
source = "hashicorp/azurerm"
Expand Down Expand Up @@ -30,7 +30,7 @@ locals {
# This allows us to randomize the region for the resource group.
module "regions" {
source = "Azure/regions/azurerm"
version = ">= 0.3.0"
version = "~> 0.6"
}

# This allows us to randomize the region for the resource group.
Expand All @@ -43,7 +43,7 @@ resource "random_integer" "region_index" {
# This ensures we have unique CAF compliant names for our resources.
module "naming" {
source = "Azure/naming/azurerm"
version = ">= 0.3.0"
version = "~> 0.4"
}

# This is required for resource modules
Expand Down Expand Up @@ -93,7 +93,7 @@ resource "azurerm_log_analytics_workspace" "this_workspace" {
module "default" {
source = "../../"
# source = "Azure/avm-res-cache-redis/azurerm"
# version = "0.1.0"
# version = "0.1.1"

enable_telemetry = var.enable_telemetry
name = module.naming.redis_cache.name_unique
Expand Down
2 changes: 1 addition & 1 deletion locals.version.tf.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"locals": {
"module_version": "0.1.0"
"module_version": "0.1.1"
}
}
5 changes: 5 additions & 0 deletions outputs.tf
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
output "name" {
description = "The name of the redis resource"
value = azurerm_redis_cache.this.name
}

output "private_endpoints" {
description = "A map of private endpoints. The map key is the supplied input to var.private_endpoints. The map value is the entire azurerm_private_endpoint resource."
value = azurerm_private_endpoint.this
Expand Down
2 changes: 1 addition & 1 deletion terraform.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
terraform {
required_version = ">= 1.5.0"
required_version = "~> 1.7"
required_providers {
azapi = {
source = "Azure/azapi"
Expand Down

0 comments on commit ab9d305

Please sign in to comment.