Frederick F. Kautz IV 2960ad15e5 Migrating example to newer libraries | 5 سال پیش | |
---|---|---|
LICENSE | 7 سال پیش | |
README.md | 5 سال پیش | |
example.go | 6 سال پیش | |
example_test.go | 7 سال پیش | |
go.mod | 5 سال پیش | |
go.sum | 5 سال پیش | |
health.go | 6 سال پیش | |
metrics.go | 6 سال پیش | |
setup.go | 5 سال پیش | |
setup_test.go | 5 سال پیش |
example - prints "example" on every query received.
The example plugin prints "example" on every query received. It serves as documentation for writing CoreDNS plugins.
example
If monitoring is enabled (via the prometheus directive) the following metric is exported:
coredns_example_request_count_total{server}
- query count to the example plugin.The server
label indicated which server handled the request, see the metrics plugin for details.
This plugin implements dynamic health checking. It will always return healthy though.
In this configuration, we forward all queries to 9.9.9.9 and print "example" whenever we receive a query.
. {
forward . 9.9.9.9
example
}
See the manual.