dockdns
Example
{config, ...}: {
dockdns = {
enable = true;
# Cloudflare API-Token for domain "example.com"
extraEnv.EXAMPLE_COM_API_TOKEN.fromFile = config.sops.secrets."dockdns/cf_api_token".path;
settings.domains = [
{
# Setup Dyn-DNS for one endpoint
name = "vpn.example.com";
}
];
};
}Stack Options
nps.stacks.dockdns.containers.dockdns
Alias of {option}services.podman.containers.dockdns.
nps.stacks.dockdns.enable
Whether to enable DockDNS. This will run a Cloudflare DNS client that updates DNS records based on Docker labels.
The module contains an extension that will automatically create DNS records for services with the public Traefik middleware,
so they are accessible from the internet. Optionally it will also automatically delete DNS records for services, that are no longer exposed (e.g. private middleware)
nps.stacks.dockdns.extraEnv
Extra environment variables to set for the container. Variables can be either set directly or sourced from a file (e.g. for secrets).
See https://github.com/Tarow/dockdns?tab=readme-ov-file#configuration
attribute set of (null or boolean or signed integer or string or absolute path or (submodule))
{ }
{
FOO = "bar";
SOME_SECRET = {
fromFile = "/run/secrets/secret_name";
};
}
nps.stacks.dockdns.settings
Settings for DockDNS.
For details, refer to the DockDNS documentation
The module will provide a default configuration, that updates DNS records every 10 minutes.
DockDNS labels will be automatically added to services with the public Traefik middleware.
nps.stacks.dockdns.useSocketProxy
Whether to access the Podman socket through the read-only proxy for the dockdns stack. Will be enabled by default if the 'docker-socket-proxy' stack is enabled.
boolean
config.nps.stacks.docker-socket-proxy.enable