external-dns for Anexia CloudDNS
The Anexia Webhook Provider for ExternalDNS allows you to use Anexia’s DNS API to manage DNS records for your domains.
The provider is heavily inspired by the ExternalDNS - IONOS Webhook and some inspiration taken from the External DNS - Adguard Home Provider.
The initial work was by done by @ProbstenHias, who still serves as the primary maintainer. Thanks a lot! :purple_heart:
Configuration
See cmd/webhook/init/configuration/configuration.go for all available configuration options for the webhook sidecar, and internal/anexia/configuration.go for all available configuration options for the Anexia provider.
Kubernetes Deployment
The Anexia Webhook Provider is provided as an OCI image in ghcr.io/anexia/k8s-external-dns-webhook.
A full tutorial of the ExternalDNS in combination with Anexia CloudDNS can be viewed in the official ExternalDNS tutorials.
The following is an example deployment for the Anexia Webhook Provider:
1helm repo add external-dns https://kubernetes-sigs.github.io/external-dns/
2
3# create the anexia configuration
4kubectl create secret generic anexia-credentials \
5 --from-literal=token='<ANEXIA_API_TOKEN>'
6
7# create the helm values file
8cat <<EOF > external-dns-anexia-values.yaml
9
10# -- ExternalDNS Log level.
11logLevel: debug # reduce in production
12
13# -- if true, _ExternalDNS_ will run in a namespaced scope (Role and Rolebinding will be namespaced too).
14namespaced: false
15
16# -- _Kubernetes_ resources to monitor for DNS entries.
17sources:
18 - ingress
19 - service
20 - crd
21
22extraArgs:
23 ## must override the default value with port 8888 with port 8080 because this is hard-coded in the helm chart
24 - --webhook-provider-url=http://localhost:8080
25 ## You should filter the domains that can be requested to limit the amount of requests done to the anxia engine.
26 ## This will help you avoid running into rate limiting
27 - --domain-filter=your.domain.com
28
29provider:
30 name: webhook
31 webhook:
32 image:
33 repository: ghcr.io/anexia/k8s-external-dns-webhook
34 tag: v0.2.4
35 env:
36 - name: LOG_LEVEL
37 value: debug # reduce in production
38 - name: ANEXIA_API_TOKEN
39 valueFrom:
40 secretKeyRef:
41 name: anexia-credentials
42 key: token
43 - name: SERVER_HOST
44 value: "0.0.0.0"
45 - name: SERVER_PORT
46 value: "8080"
47 - name: DRY_RUN
48 value: "false"
49EOF
50
51# install external-dns with helm
52helm upgrade -i external-dns-anexia external-dns/external-dns -f external-dns-anexia-values.yaml