mirror of
https://github.com/coredns/coredns.git
synced 2025-10-29 01:04:15 -04:00
kubernetes: fix the type (#2208)
client-go is a "empty interface" waste-land and we're missing an integration test so we didn't catch. Try this. Signed-off-by: Miek Gieben <miek@miek.nl>
This commit is contained in:
@@ -115,7 +115,7 @@ func newdnsController(kubeClient kubernetes.Interface, opts dnsControlOpts) *dns
|
|||||||
ListFunc: serviceListFunc(dns.client, api.NamespaceAll, dns.selector),
|
ListFunc: serviceListFunc(dns.client, api.NamespaceAll, dns.selector),
|
||||||
WatchFunc: serviceWatchFunc(dns.client, api.NamespaceAll, dns.selector),
|
WatchFunc: serviceWatchFunc(dns.client, api.NamespaceAll, dns.selector),
|
||||||
},
|
},
|
||||||
&object.Service{},
|
&api.Service{},
|
||||||
opts.resyncPeriod,
|
opts.resyncPeriod,
|
||||||
cache.ResourceEventHandlerFuncs{AddFunc: dns.Add, UpdateFunc: dns.Update, DeleteFunc: dns.Delete},
|
cache.ResourceEventHandlerFuncs{AddFunc: dns.Add, UpdateFunc: dns.Update, DeleteFunc: dns.Delete},
|
||||||
cache.Indexers{svcNameNamespaceIndex: svcNameNamespaceIndexFunc, svcIPIndex: svcIPIndexFunc},
|
cache.Indexers{svcNameNamespaceIndex: svcNameNamespaceIndexFunc, svcIPIndex: svcIPIndexFunc},
|
||||||
@@ -128,7 +128,7 @@ func newdnsController(kubeClient kubernetes.Interface, opts dnsControlOpts) *dns
|
|||||||
ListFunc: podListFunc(dns.client, api.NamespaceAll, dns.selector),
|
ListFunc: podListFunc(dns.client, api.NamespaceAll, dns.selector),
|
||||||
WatchFunc: podWatchFunc(dns.client, api.NamespaceAll, dns.selector),
|
WatchFunc: podWatchFunc(dns.client, api.NamespaceAll, dns.selector),
|
||||||
},
|
},
|
||||||
&object.Pod{},
|
&api.Pod{},
|
||||||
opts.resyncPeriod,
|
opts.resyncPeriod,
|
||||||
cache.ResourceEventHandlerFuncs{AddFunc: dns.Add, UpdateFunc: dns.Update, DeleteFunc: dns.Delete},
|
cache.ResourceEventHandlerFuncs{AddFunc: dns.Add, UpdateFunc: dns.Update, DeleteFunc: dns.Delete},
|
||||||
cache.Indexers{podIPIndex: podIPIndexFunc},
|
cache.Indexers{podIPIndex: podIPIndexFunc},
|
||||||
|
|||||||
Reference in New Issue
Block a user