Skip to content

Commit 7915585

Browse files
authored
Merge pull request #10 from clebertsuconic/new-readme
Adding some README information on how to consume this example
2 parents be977db + 773b4b6 commit 7915585

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

README.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,31 @@
99
The example plugin prints "example" on every query that go handled by the server. It serves as
1010
documentation for writing CoreDNS plugins.
1111

12+
## Compilation
13+
14+
This package will always be compiled as part of CoreDNS and not in a standalone way. It will require you to use `go get` or as a dependency on [plugin.cfg](https://github.com/coredns/coredns/blob/master/plugin.cfg).
15+
16+
The [manual](https://coredns.io/manual/toc/#what-is-coredns) will have more information about how to configure and extend the server with external plugins.
17+
18+
A simple way to consume this plugin, is by adding the following on [plugin.cfg](https://github.com/coredns/coredns/blob/master/plugin.cfg), and recompile it as [detailed on coredns.io](https://coredns.io/2017/07/25/compile-time-enabling-or-disabling-plugins/#build-with-compile-time-configuration-file).
19+
20+
~~~
21+
example:github.com/coredns/example
22+
~~~
23+
24+
After this you can compile coredns by:
25+
26+
```shell script
27+
go generate
28+
go build
29+
```
30+
31+
Or you can instead use make:
32+
33+
```shell script
34+
make
35+
```
36+
1237
## Syntax
1338

1439
~~~ txt

0 commit comments

Comments
 (0)