Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 14 additions & 12 deletions README.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ name: "aws-eks-external-dns"
github_repo: "cloudposse-terraform-components/aws-eks-external-dns"
# Short description of this project
description: |-
This component creates a Helm deployment for [external-dns](https://github.com/bitnami/bitnami-docker-external-dns) on a
Kubernetes cluster. [external-dns](https://github.com/bitnami/bitnami-docker-external-dns) is a Kubernetes addon that
This component creates a Helm deployment for [external-dns](https://github.com/kubernetes-sigs/external-dns) on a
Kubernetes cluster. [external-dns](https://github.com/kubernetes-sigs/external-dns) is a Kubernetes addon that
configures public DNS servers with information about exposed Kubernetes services to make them discoverable.

usage: |-
Expand All @@ -28,8 +28,8 @@ usage: |-
enabled: true
name: external-dns
chart: external-dns
chart_repository: https://charts.bitnami.com/bitnami
chart_version: "6.33.0"
chart_repository: https://kubernetes-sigs.github.io/external-dns/
chart_version: "1.18.0"
create_namespace: true
kubernetes_namespace: external-dns
resources:
Expand All @@ -43,13 +43,15 @@ usage: |-
# For example, when using blue-green deployment pattern to update EKS cluster.
txt_prefix: ""
# You can use `chart_values` to set any other chart options. Treat `chart_values` as the root of the doc.
# See documentation for latest chart version and list of chart_values: https://artifacthub.io/packages/helm/bitnami/external-dns
# See documentation for latest chart version and list of chart_values: https://artifacthub.io/packages/helm/external-dns/external-dns
#
# # For example
# ---
# chart_values:
# aws:
# batchChangeSize: 1000
# provider:
# name: aws
# extraArgs:
# - --aws-batch-change-size=1000
chart_values: {}
# Extra hosted zones to lookup and support by component name
dns_components:
Expand All @@ -65,11 +67,11 @@ usage: |-

references:
- name: external-dns (Artifact Hub)
url: https://artifacthub.io/packages/helm/bitnami/external-dns
description: Helm chart for ExternalDNS by Bitnami
- name: ExternalDNS (Bitnami Docker)
url: https://github.com/bitnami/bitnami-docker-external-dns
description: ExternalDNS addon container image and docs by Bitnami
url: https://artifacthub.io/packages/helm/external-dns/external-dns
description: Helm chart for ExternalDNS by Kubernetes SIGs
- name: ExternalDNS (GitHub)
url: https://github.com/kubernetes-sigs/external-dns
description: ExternalDNS addon source code and documentation
tags:
- component/eks/external-dns
- layer/eks
Expand Down
23 changes: 12 additions & 11 deletions src/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 8 additions & 9 deletions src/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ module "external_dns" {
]

effect = "Allow"
resources = formatlist("arn:${join("", data.aws_partition.current.*.partition)}:route53:::hostedzone/%s", local.zone_ids)
resources = formatlist("arn:${data.aws_partition.current[0].partition}:route53:::hostedzone/%s", local.zone_ids)
},
{
sid = "GrantListHostedZonesListResourceRecordSets"
Expand Down Expand Up @@ -96,15 +96,14 @@ module "external_dns" {
}) : "",
# external-dns-specific values
yamlencode({
aws = {
region = var.region
provider = {
name = "aws"
}
policy = var.policy
publishInternalServices = var.publish_internal_services
txtOwnerId = local.txt_owner
txtPrefix = local.txt_prefix
sources = local.sources
domainFilters = local.zone_names
policy = var.policy
txtOwnerId = local.txt_owner
txtPrefix = local.txt_prefix
sources = local.sources
domainFilters = local.zone_names
}),
# hardcoded values
file("${path.module}/resources/values.yaml"),
Expand Down
15 changes: 5 additions & 10 deletions src/resources/values.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
aws:
evaluateTargetHealth: false
rbac:
## Service Account for pods
## https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/
## RBAC API version
apiVersion: v1
## Podsecuritypolicy
pspEnabled: false
provider: aws
# AWS provider configuration for external-dns
# The official external-dns chart uses provider.name instead of the provider field
# AWS-specific settings are configured via extraArgs
extraArgs:
- --aws-evaluate-target-health=false
6 changes: 1 addition & 5 deletions src/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -142,11 +142,7 @@ variable "dns_components" {
default = []
}

variable "publish_internal_services" {
type = bool
description = "Allow external-dns to publish DNS records for ClusterIP services"
default = true
}


variable "policy" {
type = string
Expand Down
16 changes: 9 additions & 7 deletions test/fixtures/stacks/catalog/usecase/basic.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ components:
dns_gbl_primary_environment_name: ue2
name: external-dns
chart: external-dns
chart_repository: https://charts.bitnami.com/bitnami
chart_version: "6.33.0"
chart_repository: https://kubernetes-sigs.github.io/external-dns/
chart_version: "1.18.0"
create_namespace: true
kubernetes_namespace: external-dns
resources:
Expand All @@ -25,16 +25,18 @@ components:
# For example, when using blue-green deployment pattern to update EKS cluster.
txt_prefix: ""
# You can use `chart_values` to set any other chart options. Treat `chart_values` as the root of the doc.
# See documentation for latest chart version and list of chart_values: https://artifacthub.io/packages/helm/bitnami/external-dns
# See documentation for latest chart version and list of chart_values: https://artifacthub.io/packages/helm/external-dns/external-dns
#
# # For example
# ---
# chart_values:
# aws:
# batchChangeSize: 1000
# provider:
# name: aws
# extraArgs:
# - --aws-batch-change-size=1000
chart_values:
crd:
create: true
provider:
name: aws
sources:
- crd
- service
Expand Down
14 changes: 8 additions & 6 deletions test/fixtures/stacks/catalog/usecase/disabled.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ components:
dns_gbl_primary_environment_name: ue2
name: external-dns
chart: external-dns
chart_repository: https://charts.bitnami.com/bitnami
chart_version: "6.33.0"
chart_repository: https://kubernetes-sigs.github.io/external-dns/
chart_version: "1.18.0"
create_namespace: true
kubernetes_namespace: external-dns
resources:
Expand All @@ -25,13 +25,15 @@ components:
# For example, when using blue-green deployment pattern to update EKS cluster.
txt_prefix: ""
# You can use `chart_values` to set any other chart options. Treat `chart_values` as the root of the doc.
# See documentation for latest chart version and list of chart_values: https://artifacthub.io/packages/helm/bitnami/external-dns
# See documentation for latest chart version and list of chart_values: https://artifacthub.io/packages/helm/external-dns/external-dns
#
# # For example
# ---
# chart_values:
# aws:
# batchChangeSize: 1000
# provider:
# name: aws
# extraArgs:
# - --aws-batch-change-size=1000
chart_values: {}
# Extra hosted zones to lookup and support by component name
dns_components: []
dns_components: []
Loading