Sign inSign up

ff0x/dyndns-operator

By ff0x

Updated over 2 years ago

Container image for Kubernetes running a small DynDNS operator

Image
0

1.6K

ff0x/dyndns-operator repository overview

DynDNS Operator

This is an "flant/shell-operator" based container image for Kubernetes, running a small DynDNS operator, that watches for changes in a CRD named "DynDNSPool" and ensures that every subdomain in this pool points to the current external IP address, creating A/AAAA records in the corresponding DNS zone.

Currently only Gandi is supported as DNS provider.

Usage

Apply CRD:

kubectl apply -f contrib/crd.yml

Edit and deploy all manifests, please see manifests/04-Deployment.yaml for available configuration options and manifests/05-DynDNSPool.yaml for an example CRD configuration.

kubectl create secret -n dyndns generic gandi-credentials \
    --from-literal=token="$GANDI_API_TOKEN" --dry-run=client -o yaml | kubectl apply -f -
kubectl apply -f manifests/

The operator creates two cronjobs one for scheduling updates of the external IP addresses (default: every 25 min) and one for updating all rrsets in each CRD/DynDNSPool object (default: every 3 min). Additionally the operator track changes on the DynDNSPools and synchronize them with the DNS provider.

It will add annotations to every DynDNSPools showing the current external IP addresses set.

kubectl get dyndnspools dynamic-dns-pool -o json | jq -r '.metadata.annotations'

If persistence is enabled, the operator is able to delete managed DNS records beyond the container runtime.

Repo: https://git.sr.ht/~ff0x/dyndns-operator

Tag summary

Content type

Image

Digest

sha256:835f8221a

Size

36.6 MB

Last updated

over 2 years ago

docker pull ff0x/dyndns-operator