-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Customizable DNS resolver settings #625
Conversation
Customizable DNS resolver settings
Nice. Can you update the new configuration branch with the proper defaults and comments in kong.yml? |
Yep, doing it now. |
Also updating the website. |
Also I believe the less nested the properties are, the better (for un commenting) Like:
And resolver can either take an IP address, or "dnsmasq". Simply explain it in the comments. Then in the configuration parsing file, just put resolver the final ip address and add a flag to the config object if it is dnsmasq. Much simpler for users, not nested. |
Also dnsmasq is now an optional dependency. It should probably be removed from all the installation methods and in the comments of the config file we explain that it needs to be installed if enabled |
In this case dnsmasq is always listening on
Although now we offer more flexibility, dnsmasq is still the default and preferred option because with dnsmasq we will use whatever local setting has been configured for DNS resolutions (that includes For this reason substantially this PR doesn't change how DNS resolution works in Kong, it just enables more flexibility. |
About the first point, then just make the property |
I thought about it, but the condition here is "use either dnsmasq, or a custom address, but not both". I thought about giving a prioritization so if the Having this: resolver: 8.8.8.8
dnsmasq_port: 8053 Doesn't really make clear which one is going to be used. While this: dns_resolver:
address: "8.8.8.8:53"
dnsmasq:
enabled: false
port: 8053 makes it more clear IMHO. Basically I decided a more verbose, but more understandable, solution over a less verbose one that would also be less clear. |
Not if you explain it in the comments, it makes everything much more concise and the properties are easier to tweaks (and in comment) when they are not nested.
|
Or: dns_resolver: /dns_resolver_address: 8.8.8.8 dnsmasq_port: xxxx With appropriate comments for each. Better?
|
Another thing to consider is that the dns_resolver:
ipv6: true,
ttl: 30 # 30 seconds
address: "8.8.8.8:53"
dnsmasq:
enabled: false
port: 8053 These two properties would be effective for both custom address, or dnsmasq, so makes sense to have a parent |
I could implement those two additional properties now too, btw. |
What really bother me is how nested in the |
No description provided.