external-dns-extensions

by emberstack

Helm chartv1.0.22App 1.0.0MITVerified publisher

A Helm chart for external-dns extensions

About this chart

external-dns Helm Extensions

This chart provides templates for external-dns CRDs. It can be used as the base for dynamic resources.

Requirements: external-dns installed in the cluster, with its CRD source enabled (--source=crd).

Templates target externaldns.k8s.io/v1alpha1 as shipped with external-dns v0.22.0.

KindValues keyShapeMinimum external-dns
DNSEndpointdnsEndpointsone resource, many endpointsv0.5
DNSRecorddnsRecordsone resource per recordv0.22.0

Both sections are lists; each entry needs its own name and is opt-in via enabled: true.

DNSRecord is new in external-dns v0.22.0 — the CRD does not exist in earlier releases, so that section renders resources an older cluster will not recognise. DNSEndpoint's schema is unchanged between v0.21 and v0.22.

Every endpoint requires dnsName, recordType and targets. Validation reports the exact path (e.g. dnsEndpoints[0].endpoints[2]: targets is required).

Installation

Using OCI registry (recommended)

helm install external-dns-extensions oci://ghcr.io/emberstack/helm-charts/external-dns-extensions

Using Helm repository

helm repo add emberstack https://emberstack.github.io/helm-charts
helm repo update
helm upgrade --install external-dns-extensions emberstack/external-dns-extensions

Parameters

ParameterDescriptionDefault
nameOverrideOverride chart name""
fullnameOverrideOverride fully qualified app name""
namespaceOverrideOverride namespace""
commonLabelsLabels added to all resources{}
commonAnnotationsAnnotations added to all resources{}
dnsEndpointsList of DNSEndpoints[]
dnsRecordsList of DNSRecords[]

Per-entry keys: name (required), enabled, fullnameOverride, namespace, labels, annotations.

Endpoint fields: dnsName, recordType, targets (all required), plus recordTTL, setIdentifier, labels and providerSpecific.

See values.yaml for the full annotated reference.

Usage Examples

DNSEndpoint with A and CNAME records

dnsEndpoints:
  - name: app-records
    enabled: true
    endpoints:
      - dnsName: app.example.com
        recordType: A
        recordTTL: 300
        targets:
          - 203.0.113.10
          - 203.0.113.11
      - dnsName: www.example.com
        recordType: CNAME
        recordTTL: 300
        targets:
          - app.example.com

Weighted records with setIdentifier

dnsEndpoints:
  - name: weighted
    enabled: true
    endpoints:
      - dnsName: api.example.com
        recordType: A
        setIdentifier: blue
        targets: [203.0.113.10]
        providerSpecific:
          - name: aws/weight
            value: "80"
      - dnsName: api.example.com
        recordType: A
        setIdentifier: green
        targets: [203.0.113.20]
        providerSpecific:
          - name: aws/weight
            value: "20"

Provider-specific options

dnsEndpoints:
  - name: proxied
    enabled: true
    endpoints:
      - dnsName: cdn.example.com
        recordType: A
        targets: [203.0.113.30]
        providerSpecific:
          - name: external-dns.alpha.kubernetes.io/cloudflare-proxied
            value: "true"

DNSRecord (external-dns >= v0.22.0)

dnsRecords:
  - name: app-a-record
    enabled: true
    endpoint:
      dnsName: app.example.com
      recordType: A
      recordTTL: 300
      targets:
        - 203.0.113.10

Templated targets

dnsEndpoints:
  - name: templated
    enabled: true
    endpoints:
      - dnsName: "{{ .Release.Name }}.example.com"
        recordType: CNAME
        targets:
          - "ingress.{{ .Release.Namespace }}.example.com"

Deploy external-dns-extensions with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has external-dns-extensions on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartexternal-dns-extensions is pinned at v1.0.22 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply