aboutsummaryrefslogtreecommitdiff
path: root/plugin/k8s_external/external.go
diff options
context:
space:
mode:
Diffstat (limited to 'plugin/k8s_external/external.go')
-rw-r--r--plugin/k8s_external/external.go12
1 files changed, 9 insertions, 3 deletions
diff --git a/plugin/k8s_external/external.go b/plugin/k8s_external/external.go
index 720556969..c584b3414 100644
--- a/plugin/k8s_external/external.go
+++ b/plugin/k8s_external/external.go
@@ -29,9 +29,13 @@ type Externaler interface {
External(request.Request) ([]msg.Service, int)
// ExternalAddress should return a string slice of addresses for the nameserving endpoint.
ExternalAddress(state request.Request) []dns.RR
+ // ExternalServices returns all services in the given zone as a slice of msg.Service.
+ ExternalServices(zone string) []msg.Service
+ // ExternalSerial gets the current serial.
+ ExternalSerial(string) uint32
}
-// External resolves Ingress and Loadbalance IPs from kubernetes clusters.
+// External serves records for External IPs and Loadbalance IPs of Services in Kubernetes clusters.
type External struct {
Next plugin.Handler
Zones []string
@@ -42,8 +46,10 @@ type External struct {
upstream *upstream.Upstream
- externalFunc func(request.Request) ([]msg.Service, int)
- externalAddrFunc func(request.Request) []dns.RR
+ externalFunc func(request.Request) ([]msg.Service, int)
+ externalAddrFunc func(request.Request) []dns.RR
+ externalSerialFunc func(string) uint32
+ externalServicesFunc func(string) []msg.Service
}
// New returns a new and initialized *External.