1.11.1-3 • Published 3 months ago

coredns-dist v1.11.1-3

Weekly downloads
-
License
MIT
Repository
github
Last release
3 months ago

coredns-dist

Use coredns as an npm module for tighter integration with node apps (e.g. test fixtures). See the coreDNS documentation for usage: https://coredns.io/manual/toc/.

Usage

npm install coredns-dist

Put a Corefile in the current working directory.

import coredns from "coredns-dist";
const server = await coredns();
// You can also pass in a custom environment
const server = await coredns({
  MY_VARIABLE: "www.example.org",
});

// And shut down when you are done
server.stop();
sudo setcap 'cap_net_bind_service=+ep' ../linux-x64/coredns
dig @127.0.0.1 -p 1053 www.example.com