Doc: add package docs (#296)
* Doc: add package docs Add short package level docs to make godoc looks nicer. Add some badges to the README. * correct url
This commit is contained in:
parent
edc867fe56
commit
de0fa53379
24 changed files with 35 additions and 2 deletions
|
@ -1,5 +1,8 @@
|
||||||
# CoreDNS
|
# CoreDNS
|
||||||
|
|
||||||
|
[](https://godoc.org/github.com/miekg/coredns)
|
||||||
|
[](https://travis-ci.org/miekg/coredns)
|
||||||
|
|
||||||
CoreDNS is a DNS server that started as a fork of [Caddy](https://github.com/mholt/caddy/). It has the
|
CoreDNS is a DNS server that started as a fork of [Caddy](https://github.com/mholt/caddy/). It has the
|
||||||
same model: it chains middleware. In fact it's so similar that CoreDNS is now a server type plugin for
|
same model: it chains middleware. In fact it's so similar that CoreDNS is now a server type plugin for
|
||||||
Caddy.
|
Caddy.
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package core registers the server and all plugins we support.
|
||||||
package core
|
package core
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// Package DNS server implements all the interfaces from Caddy, so that
|
||||||
|
// CoreDNS can be a servertype plugin.
|
||||||
package dnsserver
|
package dnsserver
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package coremain contains the functions for starting CoreDNS.
|
||||||
package coremain
|
package coremain
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package bind allows binding to a specific interface instead of bind to all of them.
|
||||||
package bind
|
package bind
|
||||||
|
|
||||||
import "github.com/mholt/caddy"
|
import "github.com/mholt/caddy"
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package chaos implements a middleware that answer to 'CH version.bind TXT' type queries.
|
||||||
package chaos
|
package chaos
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// Package dnssec implements a middleware that signs responses on-the-fly using
|
||||||
|
// NSEC black lies.
|
||||||
package dnssec
|
package dnssec
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// Package etcd provides the etcd backend.
|
// Package etcd provides the etcd backend middleware.
|
||||||
package etcd
|
package etcd
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package msg defines the Service structure which is used for service discovery.
|
||||||
package msg
|
package msg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package file implements a file backend.
|
||||||
package file
|
package file
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package health implements an HTTP handler that responds to health checks.
|
||||||
package health
|
package health
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -17,8 +17,8 @@ import (
|
||||||
"github.com/miekg/dns"
|
"github.com/miekg/dns"
|
||||||
"k8s.io/kubernetes/pkg/api"
|
"k8s.io/kubernetes/pkg/api"
|
||||||
unversionedapi "k8s.io/kubernetes/pkg/api/unversioned"
|
unversionedapi "k8s.io/kubernetes/pkg/api/unversioned"
|
||||||
unversionedclient "k8s.io/kubernetes/pkg/client/unversioned"
|
|
||||||
"k8s.io/kubernetes/pkg/client/restclient"
|
"k8s.io/kubernetes/pkg/client/restclient"
|
||||||
|
unversionedclient "k8s.io/kubernetes/pkg/client/unversioned"
|
||||||
"k8s.io/kubernetes/pkg/client/unversioned/clientcmd"
|
"k8s.io/kubernetes/pkg/client/unversioned/clientcmd"
|
||||||
clientcmdapi "k8s.io/kubernetes/pkg/client/unversioned/clientcmd/api"
|
clientcmdapi "k8s.io/kubernetes/pkg/client/unversioned/clientcmd/api"
|
||||||
"k8s.io/kubernetes/pkg/labels"
|
"k8s.io/kubernetes/pkg/labels"
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package loadbalance shuffles A and AAAA records.
|
||||||
package loadbalance
|
package loadbalance
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// Package metrics implement a handler and middleware that provides Prometheus
|
||||||
|
// metrics.
|
||||||
package metrics
|
package metrics
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package dnsrecorder allows you to record a DNS response when it is send to the client.
|
||||||
package dnsrecorder
|
package dnsrecorder
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
2
middleware/pkg/dnsutil/doc.go
Normal file
2
middleware/pkg/dnsutil/doc.go
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
// Package dnsutil contains DNS related helper functions.
|
||||||
|
package dnsutil
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package edns provides function usefull for adding/inspecting OPT records to/in messages.
|
||||||
package edns
|
package edns
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package storage abstracts away where middleware can store assests (zones, keys, etc).
|
||||||
package storage
|
package storage
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// Package pprof implement a debug endpoint for getting profiles using the
|
||||||
|
// go pprof tooling.
|
||||||
package pprof
|
package pprof
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// Package secondary implements a secondary middleware.
|
||||||
package secondary
|
package secondary
|
||||||
|
|
||||||
import "github.com/miekg/coredns/middleware/file"
|
import "github.com/miekg/coredns/middleware/file"
|
||||||
|
|
2
middleware/test/doc.go
Normal file
2
middleware/test/doc.go
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
// Package test contains helper functions for writing middleware tests.
|
||||||
|
package test
|
|
@ -1,3 +1,5 @@
|
||||||
|
// Package whoami implements a middleware that returns details about the resolving
|
||||||
|
// querying it.
|
||||||
package whoami
|
package whoami
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// Package requests abstract a client's request so that all middleware
|
||||||
|
// will handle them in an unified way.
|
||||||
package request
|
package request
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
2
test/doc.go
Normal file
2
test/doc.go
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
// Package test contains function and types useful for writing tests
|
||||||
|
package test
|
Loading…
Add table
Reference in a new issue