CoreDNS plugins need to be compiled into CoreDNS, you can follow the build instructions to build the binaries or use the provided docker images.
- Create Omada user
- Setup network
- Run CoreDNS with omada plugin
- Login to Omada controller
- Go to Global View > Account (bottom of the left nav bar) -> Add New User
- Choose "Local User"
- Role: "Viewer"
- Site Privileges: "All" or select the individual site
- Make a note of the username and password
- From the Omada controller go to Settings -> Wired Networks -> LAN and choose your network(s):
Domain Namemust be set (e.gomada.home)DNS Serverset toManualand enter the IP address of your CoreDNS application.
This guide provides three options on how to run CoreDNS:
- [CoreDNS binary](#coredns-binary)
- [Docker](#docker)
- [Kubernetes](#kubernetes)
To build the CoreDNS binary with the omada plugin follow the steps provided here. Once built setup you Corefile and then run coredns.
Example:
./coredns -conf ./Corefile
Note: If you do not have a valid https certificate on your controller then set the OMADA_DISABLE_HTTPS_VERIFICATION environment variable to true
- Use the pre-built images or build your own
- Pre-built images are published here
- The pre-built images contain a default corefile which requires the following environment variables to be set:
OMADA_URLOMADA_SITEOMADA_USERNAMEOMADA_PASSWORDUPSTREAM_DNS
The pre-built images support these optional environment variables:
OMADA_IGNORE_STARTUP_ERRORS=true|falseFALLTHROUGH_ZONES- defaults to all zones.to maintain previous compatibility. To disable fallthrough completely either set this a a fake zone (e.gFALLTHROUGH_ZONES=disabled) or mount a custom Corefile.
Note: If you do not have a valid https certificate on your controller then set the OMADA_DISABLE_HTTPS_VERIFICATION environment variable to true
Example docker run command:
docker run \
--rm -it \
--expose=53 --expose=53/udp -p 53:53 -p 53:53/udp \
--env OMADA_URL="<OMADA_URL>" \
--env OMADA_SITE="<OMADA_SITE>" \
--env OMADA_USERNAME="<OMADA_USERNAME>" \
--env OMADA_PASSWORD="<OMADA_PASSWORD>" \
--env OMADA_IGNORE_STARTUP_ERRORS="false" \
--env OMADA_DISABLE_HTTPS_VERIFICATION="false" \
--env UPSTREAM_DNS="8.8.8.8" \
ghcr.io/dougbw/coredns_omada:latest
To use a custom Corefile mount the file as a volume to \Corefile and supply any required environment variables:
docker run \
--rm -it \
--expose=53 --expose=53/udp -p 53:53 -p 53:53/udp \
--env OMADA_DISABLE_HTTPS_VERIFICATION="false" \
-v "${PWD}/Corefile":/Corefile \
ghcr.io/dougbw/coredns_omada:latest
Example manifest files to get started are in the k8s directory. Make sure you replace the following values:
- configmap.yaml
omada-urlomada-siteomada-usernameupstream-dns- Note: if you do not have a valid https certification on your controller then set
omada-disable-https-verificationtotrue
- secret.yaml
omada-password
