yyyar / gobetween

:cloud: Modern & minimalistic load balancer for the Сloud era
http://gobetween.io
Other
1.91k stars 210 forks source link

Skip RRSIG records in response. #328

Open blakerouse opened 2 years ago

blakerouse commented 2 years ago

Fixes #327.

Without this change a domain that as DNSSEC enabled resulted in the following output:

{"level":"info","msg":"Fetching 1.1.1.1:53 _api._tcp.k8s.example.net.","name":"srvFetch","time":"2022-02-27T12:30:28Z"}
{"level":"debug","msg":"Fetching 1.1.1.1:53 A/AAAA node1.example.net.","name":"srvFetch","time":"2022-02-27T12:30:28Z"}
{"level":"warning","msg":"No IP found for node1.example.net., skipping...","name":"srvFetch","time":"2022-02-27T12:30:28Z"}
{"level":"error","msg":"srv error Non-SRV record in SRV answer retrying in 2s","name":"discovery","time":"2022-02-27T12:30:28Z"}
{"level":"info","msg":"Applying failpolicy keeplast","name":"discovery","time":"2022-02-27T12:30:28Z"}

With this change the result is:

{"level":"debug","msg":"Fetching 1.1.1.1:53 A/AAAA node1.example.net.","name":"srvFetch","time":"2022-02-27T07:27:35-05:00"}
{"level":"debug","msg":"Initial check ping for {X.X.X.X 6443}","name":"healthcheck/worker","time":"2022-02-27T07:27:42-05:00"}
{"level":"debug","msg":"Got check result ping: {{X.X.X.X 6443} 2}","name":"healthcheck/worker","time":"2022-02-27T07:27:42-05:00"}
{"level":"info","msg":"Sending to scheduler: {{X.X.X.X 6443} 2}","name":"healthcheck/worker","time":"2022-02-27T07:27:42-05:00"}