A program that can set the IP addresses for configured DNS entries in Gandi's domain configuration. Thanks to Gandi's LiveDNS API, this creates a dynamic DNS system.
If you want to host web services but you don't have a static IP address, this tool will allow you to keep your domains pointed at the right IP address. This program can update both IPv4 and IPv6 addresses for one or more domains and subdomains. It's a one-shot tool that's meant to be managed with a systemd timer or cron.
The Gandi Live DNS API is rate limited at 30 requests per minute. This program respects this rate limit: if you have more than 30 domains to update, the program will pause and wait for a minute, plus a random delay to ensure it doesn't hit the rate limit.
Packages are available for some linux distributions.
Contributions to release this for other distributions are welcome!
gandi-live-dns provides pre-built binaries with the releases. See the
releases page to
get the latest version. These binaries are statically linked, and provided for
both Linux and Windows, including ARM architectures for the Linux version.
Download the latest version from the releases page, extract it from the archive, and place it somewhere in your $PATH to use it.
gandi.toml, then copy and paste the contents of example.tomlgandi-live-dns inside the directory with the configration to update your DNS entriesUse the seriousbug/gandi-live-dns-rust Docker images, which are available for x86_64, arm64, armv6, and armv7 platforms. Follow the steps below to use these images.
gandi.toml, then copy and paste the contents of example.tomldocker run --rm -it -v $(pwd)/gandi.toml:/gandi.toml:ro seriousbug/gandi-live-dns-rust:latestDocker doesn't support IPv6 out of the box. If you need to update IPv6 addresses, check the linked page to enable IPv6 or use the prebuilt binaries directly.
If you get errors about not finding the config file, make sure your command has a full path to the config file (
$(pwd)/gandi.tomlpart). Otherwise Docker will create a directory.
The Packaging folder contains a Systemd service and timer, which you can use
to automatically run this tool. By default it will update the IP addresses after
every boot up, and at least once a day. You can adjust the timer to speed this
up, but avoid unnecessarily overloading Gandi's servers.
gandi-live-dns.timer and gandi-live-dns.service into /etc/systemd/systemgandi-live-dns binary into /usr/bin/
/usr/local/bin or some other directory, just make sure to update the path in the service file/etc/gandi-live-dns, and place your gandi.toml into ituseradd --system gandi-live-dns --home-dir /etc/gandi-live-dnschown gandi-live-dns: /etc/gandi-live-dns/gandi.toml && chmod 600 /etc/gandi-live-dns/gandi.tomlsystemctl enable --now gandi-live-dns.timercargo build and cargo build --release are sufficient for development and release builds.
No special instructions are needed.
To make a release, first set up cross and docker. Make sure you log into
Docker with docker login. Then follow these steps:
Cargo.toml according to semver
./make-release.sh
> This will build binaries, then package them into archives, as well as
> build and upload docker images.master