Skip to content

Commit

Permalink
Revert "support CNAME if entry is not all digits"
Browse files Browse the repository at this point in the history
Alias only support A records

This reverts commit fad159b.
  • Loading branch information
wesleung committed Oct 26, 2023
1 parent fad159b commit e5f11a1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ resource "aws_route53_record" "default" {
count = "${module.enabled.value ? length(compact(var.aliases)) : 0}"
zone_id = "${data.aws_route53_zone.default.zone_id}"
name = "${element(compact(var.aliases), count.index)}"
type = "${(upper(var.target_dns_name) == var.target_dns_name && lower(var.target_dns_name) == var.target_dns_name) ? "A" : "CNAME"}"
type = "A"

alias {
name = "${var.target_dns_name}"
Expand Down

0 comments on commit e5f11a1

Please sign in to comment.