mirror of
https://github.com/coredns/coredns.git
synced 2025-10-29 09:14:17 -04:00
Stub forward/proxy tests (#108)
Test the handling of EDNS0 payloads and forwarding to stubzones servers.
This commit is contained in:
@@ -22,6 +22,7 @@ func (e Etcd) ServeDNS(ctx context.Context, w dns.ResponseWriter, r *dns.Msg) (i
|
||||
name := state.Name()
|
||||
if e.Stubmap != nil && len(*e.Stubmap) > 0 {
|
||||
for zone, _ := range *e.Stubmap {
|
||||
// TODO(miek): use the Match function.
|
||||
if strings.HasSuffix(name, zone) {
|
||||
stub := Stub{Etcd: e, Zone: zone}
|
||||
return stub.ServeDNS(ctx, w, r)
|
||||
|
||||
Reference in New Issue
Block a user