PowerDNS / dnsdist-ansible

An ansible role for dnsdist
MIT License
30 stars 32 forks source link

Cant use QPS or pool in "newServer" in dnsdist.conf #33

Open askilolsen opened 3 years ago

askilolsen commented 3 years ago

In templates/dnsdist.conf.j2 newServer is defined as: newServer("{{server}}")

This makes it hard to add additional configuration like QPS or pool, removing the '"' and defining server as: "{address='1.1.1.1', pool='testing'}"

Made it possible. Not sure if there is a good reason for using the '"' in the config, but wanted to file the issue to find out

pieterlexis commented 3 years ago

dnsdist_servers is mostly meant as a quickstart, Right now, any additional config can be done by using the dnsdist_config variable:

dnsdist_config: |
    newServer({address='1.1.1.1', pool='testing'})

I'll keep this issue open as a feature request for adding a possibility to define more properties liek this:

dnsdist_servers:
  - name: foo
    address: 192.0.2.1:5300
    pool: bar
aoxborrow commented 2 months ago

might be good to mention in the readme that if you just want to use dnsdist_config for everything, you probably want to set this to blank:

dnsdist_locals: []