erldns_zones (erldns v7.0.0-rc10)

View Source

The system responsible for loading and caching zone data.

Zones are loaded by default from JSON files in the priv/zones/ directory. The path is configured in erldns.config using the zones.path setting.

For more details about zone file format and configuration, see ZONES.

For more details about its subsections, see:

Configuration

{erldns, [
    {zones, #{
        path => "zones.json",
        strict => true,
        codecs => [sample_custom_zone_codec]
    }},
]}

See the type config/0 for details.

Summary

Types

Zone configuration.

Types

config()

-type config() :: #{path => undefined | file:name(), strict => boolean(), codecs => [module()]}.

Zone configuration.

Path can be a directory, and strict declares whether load failure should crash or be ignored. If a path is configured and strict is true, and the path is not resolvable, it will fail. See erldns_zone_loader for more details.

Codecs are a list of modules that implement the erldns_zone_codec behaviour.