CoreDNS is a fast, flexible DNS server that is designed to be performant with a flexible implementation. This flexibility allows CoreDNS to be easily extended to support various data sources and to implement rich DNS service behaviors. For example, response caching, query rewrite, load-balancing, zone transfer and signing.
CoreDNS is a focused lightweight DNS server. A microservice philosophy guides the internal design of CoreDNS. Individual DNS functions are provided by discrete, composable plugins that are enabled via runtime configuration.
CoreDNS can be thought of as a DNS protocol head that can be configured to front various backend data sources. A flexible DNS server is a necessary component to provide “Naming and Discovery” services to containers running in the CNCF distributed system services environment.
*Comparison with KubeDNS*:
The incumbent DNS service for kubernetes, “kubedns”, consists of four components:
* etcd provides a DNS data cache,
* kube2sky provides the mechanism for updating the etcd data cache,
* skydns provides the DNS service based on the data cached in etcd,
* exechealthz provides health-check status.
Running CoreDNS with kubernetes only requires the coredns component. CoreDNS does not require a separate data cache or update service. CoreDNS includes an optional health-check “middleware” component that can be used for service monitoring.
CoreDNS provides a cleaner, more extensible codebase as compared to SkyDNS. (Both SkyDNS and CoreDNS were authored by Miek Gieben.)
CoreDNS is currently being extended to operate directly with kubernetes to access the service data. This “middleware” implementation for CoreDNS provides the same client-facing behavior as KubeDNS. The pipeline-based design of CoreDNS allows easy extension to use any container orchestrator as a DNS data source.
With the kubernetes middleware, CoreDNS can be considered as an alternative to SkyDNS with lower runtime complexity. Performance testing to compare against SkyDNS is pending.