mirror of
https://github.com/coredns/coredns.git
synced 2025-10-29 17:24:20 -04:00
Publish metadata from kubernetes plugin (#2829)
* Publish metadata from kubernetes plugin * stickler fix * Add a couple tests * Add metadata section to README * Update plugin/kubernetes/README.md Co-Authored-By: Chris O'Haver <cohaver@infoblox.com> * Address nit
This commit is contained in:
committed by
Miek Gieben
parent
a1c97f82a6
commit
ffcd2f61cf
@@ -495,9 +495,12 @@ func (APIConnServeTest) EpIndexReverse(string) []*object.Endpoints { return nil
|
||||
func (APIConnServeTest) SvcIndexReverse(string) []*object.Service { return nil }
|
||||
func (APIConnServeTest) Modified() int64 { return time.Now().Unix() }
|
||||
|
||||
func (APIConnServeTest) PodIndex(string) []*object.Pod {
|
||||
func (APIConnServeTest) PodIndex(ip string) []*object.Pod {
|
||||
if ip != "10.240.0.1" {
|
||||
return []*object.Pod{}
|
||||
}
|
||||
a := []*object.Pod{
|
||||
{Namespace: "podns", PodIP: "10.240.0.1"}, // Remote IP set in test.ResponseWriter
|
||||
{Namespace: "podns", Name: "foo", PodIP: "10.240.0.1"}, // Remote IP set in test.ResponseWriter
|
||||
}
|
||||
return a
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user