mirror of
https://github.com/coredns/coredns.git
synced 2025-10-28 16:54:15 -04:00
middleware/kubernetes: cleanup (#818)
Drop the interfaceAddr interfaces and just use a function. Cleanup all fallout from that. Remove the use of global variables and cleanup the tests a bit.
This commit is contained in:
@@ -56,10 +56,10 @@ func setup(c *caddy.Controller) error {
|
||||
|
||||
func kubernetesParse(c *caddy.Controller) (*Kubernetes, error) {
|
||||
k8s := &Kubernetes{
|
||||
ResyncPeriod: defaultResyncPeriod,
|
||||
interfaceAddrs: &interfaceAddrs{},
|
||||
PodMode: PodModeDisabled,
|
||||
Proxy: proxy.Proxy{},
|
||||
ResyncPeriod: defaultResyncPeriod,
|
||||
interfaceAddrsFunc: localPodIP,
|
||||
PodMode: PodModeDisabled,
|
||||
Proxy: proxy.Proxy{},
|
||||
}
|
||||
|
||||
for c.Next() {
|
||||
|
||||
Reference in New Issue
Block a user