Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[QUESTION] Multiple Route53 Zones with ExternalDNS #541

Closed
andrewmiskell opened this issue May 12, 2022 · 2 comments · Fixed by #838
Closed

[QUESTION] Multiple Route53 Zones with ExternalDNS #541

andrewmiskell opened this issue May 12, 2022 · 2 comments · Fixed by #838
Labels
enhancement New feature or request

Comments

@andrewmiskell
Copy link

andrewmiskell commented May 12, 2022

Trying to see if it's possible to support external-dns adding records to multiple Route53 zones.

The documentation states that setting the eks_cluster_domain value is optional in order to set the zoneIdFilters, however, if I don't specify that value a get an error during apply stating.

│Error: Either name or zone_id must be set with module.eks_cluster_kubernetes_addons.module.external_dns[0].data.aws_route53_zone.selected, on .terraform/modules/eks_cluster_kubernetes_addons/modules/kubernetes-addons/external-dns/data.tf line 1, in data "aws_route53_zone" "selected": 1: data "aws_route53_zone" "selected" {

If I do set a value in eks_cluster_domain, the apply proceeds but then it sets a single zoneIdFilters with the zone id defined in eks_cluster_domain. I'd like to have the ability to either not have a zoneIdFilter (to allow it to create DNS records in any Route53 zone I have) or the ability to define multiple zoneIdFilters.

@andrewmiskell andrewmiskell added the question Further information is requested label May 12, 2022
@kcoleman731
Copy link
Contributor

@andrewmiskell thanks for creating this issue. Agree that this should be support. I'll go ahead and add this issue to the backlog.

@guilhermeblanco
Copy link

I have successfully adjusted the knobs to support multiple zones using the following config:

  # External DNS
  enable_external_dns      = true
  external_dns_helm_config = {
    version    = "6.4.6"
    namespace  = "kube-system"
    domain_name = var.tld
    values     = [
<<EOF
provider: "aws"
aws:
  region: "${var.region}"
  zoneType: "public"
  apiRetries: 3
  batchChangeSize: 1000
  preferCNAME: false

logLevel: "info"
logFormat: "text"

interval: "1m"

policy: "upsert-only"
registry: "txt"
txtOwnerId: "external-dns"
sources:
  - "service"
  - "ingress"

domainFilters: ["${join("\" ,\"", concat([var.tld], var.alternate_tlds))}"]
EOF
    ]
  }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
No open projects
4 participants