aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.md29
1 files changed, 26 insertions, 3 deletions
diff --git a/README.md b/README.md
index 64ded3ace..a8476a7b1 100644
--- a/README.md
+++ b/README.md
@@ -87,15 +87,38 @@ CoreDNS-1.6.6
linux/amd64, go1.13.5, aa8c32
~~~
+The following could be used to query the CoreDNS server that is running now:
+
+~~~ txt
+dig @127.0.0.1 -p 53 www.example.com
+~~~
+
Any query sent to port 53 should return some information; your sending address, port and protocol
used. The query should also be logged to standard output.
+The configuration of CoreDNS is done through a file named `Corefile`. When CoreDNS starts, it will
+look for the `Corefile` from the current working directory. A `Corefile` for CoreDNS server that listens
+on port `53` and enables `whoami` plugin is:
+
+~~~ corefile
+.:53 {
+ whoami
+}
+~~~
+
+Sometimes port number 53 is occupied by system processes. In that case you can start the CoreDNS server
+while modifying the Corefile as given below so that the CoreDNS server starts on port 1053.
+
+~~~ corefile
+.:1053 {
+ whoami
+}
+~~~
+
If you have a Corefile without a port number specified it will, by default, use port 53, but you can
override the port with the `-dns.port` flag: `coredns -dns.port 1053`, runs the server on port 1053.
-Start a simple proxy. You'll need to be root to start listening on port 53.
-
-`Corefile` contains:
+A Corefile for a CoreDNS server that forward any queries to an upstream DNS (e.g., `8.8.8.8`) is as follows:
~~~ corefile
.:53 {