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:
parent
8ad8c75ab4
commit
2c0fc3182c
8 changed files with 25 additions and 53 deletions
|
@ -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() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue