Skip to content

Commit 85b2a73

Browse files
updated files
1 parent 7d1850f commit 85b2a73

File tree

2 files changed

+17
-5
lines changed

2 files changed

+17
-5
lines changed

outputs.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,3 +129,9 @@ output "private_dns_zone_id" {
129129
description = "ID of a single private DNS zone module instance (if you use one)."
130130
value = try(module.private_dns_zone.id, module.private_dns_zone.zone_id, null)
131131
}
132+
133+
output "postgres_private_dns_zone_id" {
134+
description = "The ID of the Postgres private DNS zone."
135+
value = var.private_dns_zone_enabled ? azurerm_private_dns_zone.postgres[0].id : null
136+
}
137+

variables.tf

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -295,8 +295,14 @@ variable "logical_product_service" {
295295
}
296296
}
297297

298-
# variable "target_private_dns_zone_name" {
299-
# type = string
300-
# default = null
301-
# description = "If set, outputs the ID for just this zone name from private_dns_zone_ids_by_name."
302-
# }
298+
variable "target_private_dns_zone_name" {
299+
type = string
300+
default = null
301+
description = "If set, outputs the ID for just this zone name from private_dns_zone_ids_by_name."
302+
}
303+
304+
variable "private_dns_zone_enabled" {
305+
description = "Enable or disable the creation of the Postgres private DNS zone."
306+
type = bool
307+
default = false
308+
}

0 commit comments

Comments
 (0)