plugin/kubernetes: do endpoint/slice check in retry loop (#4492)

* do endpoint/slice check in retry loop

Signed-off-by: Chris O'Haver <cohaver@infoblox.com>
This commit is contained in:
Chris O'Haver
2021-03-26 08:54:39 -04:00
committed by GitHub
parent ea41dd23a0
commit 9f72db12e7
4 changed files with 141 additions and 74 deletions

View File

@@ -104,6 +104,20 @@ kubernetes [ZONES...] {
Enabling zone transfer is done by using the *transfer* plugin.
## Startup
When CoreDNS starts with the *kubernetes* plugin enabled, it will delay serving DNS for up to 5 seconds
until it can connect to the Kubernetes API and synchronize all object watches. If this cannot happen within
5 seconds, then CoreDNS will start serving DNS while the *kubernetes* plugin continues to try to connect
and synchronize all object watches. CoreDNS will answer SERVFAIL to any request made for a Kubernetes record
that has not yet been synchronized.
## Monitoring Kubernetes Endpoints
By default the *kubernetes* plugin watches Endpoints via the `discovery.EndpointSlices` API. However the
`api.Endpoints` API is used instead if the Kubernetes version does not support the `EndpointSliceProxying`
feature gate by default (i.e. Kubernetes version < 1.19).
## Ready
This plugin reports readiness to the ready plugin. This will happen after it has synced to the