2023-11-04 20:33:51 +00:00
|
|
|
resource "powerdns_record" "Cname" {
|
|
|
|
for_each = toset(var.cnameList)
|
|
|
|
zone = powerdns_zone.ducampseu.name
|
|
|
|
name = "${each.key}.${powerdns_zone.ducampseu.name}"
|
2024-02-10 09:39:09 +00:00
|
|
|
type = "ALIAS"
|
2024-02-18 14:36:45 +00:00
|
|
|
ttl = 600
|
2023-11-04 20:33:51 +00:00
|
|
|
records = [var.localEndpoint]
|
|
|
|
}
|
|
|
|
|
|
|
|
resource "hetznerdns_record" "Cname" {
|
|
|
|
for_each = var.enableHetzner ? toset(var.cnameList) : []
|
|
|
|
|
|
|
|
zone_id = hetznerdns_zone.externalZoneEU[0].id
|
|
|
|
name = each.key
|
|
|
|
value = var.cloudEndpoint
|
|
|
|
type = "A"
|
|
|
|
}
|