the bridge resolver answers other record types for its own names locally instead of waiting on an upstream
This commit is contained in:
parent
4876acd02a
commit
89bbeb9757
1 changed files with 48 additions and 13 deletions
|
|
@ -364,6 +364,21 @@ let
|
|||
&& allLocal.services.hyperhive.otel.collector.host == "hive-collector.hive"
|
||||
&& lib.elem "/hive-collector.hive/${bridge}" allLocal.services.dnsmasq.settings.address;
|
||||
}
|
||||
{
|
||||
# An `address=` rule alone sends the other record types upstream
|
||||
# (dnsmasq 2.86), so each of its domains is also `local=`, and no other
|
||||
# domain is: `local=` on a domain with public records would hide them.
|
||||
name = "the resolver keeps queries for every domain it answers itself, and only those, off the upstream";
|
||||
ok =
|
||||
let
|
||||
s = allLocal.services.dnsmasq.settings;
|
||||
domain = rule: builtins.elemAt (lib.splitString "/" rule) 1;
|
||||
answered = map domain s.address;
|
||||
in
|
||||
lib.elem "hive-collector.hive" answered
|
||||
&& map domain (s.local or [ ]) == answered
|
||||
&& lib.all (rule: lib.hasSuffix "/" rule) (s.local or [ ]);
|
||||
}
|
||||
{
|
||||
# The absence arm, and what makes the agents' queue address cases above able
|
||||
# to fail.
|
||||
|
|
|
|||
Loading…
Reference in a new issue