Skip to content

Instantly share code, notes, and snippets.

@ekanant
Created March 19, 2024 20:33
Show Gist options
  • Select an option

  • Save ekanant/4c9621b6cdd467d23594b5fb9a7a1aae to your computer and use it in GitHub Desktop.

Select an option

Save ekanant/4c9621b6cdd467d23594b5fb9a7a1aae to your computer and use it in GitHub Desktop.
Coredns learning
.:53 {
hosts /config/host {
fallthrough
}
forward . 1.1.1.1 8.8.8.8
# Cache 300 second
cache 300 {
success 10000
denial 2500
}
log
errors
}
version: '3.9'
services:
dns-server:
image: coredns/coredns:1.11.1
ports:
- "30053:53/udp"
# network_mode: "host"
command: ["-conf", "/config/Corefile"]
volumes:
- ./coredns.conf:/config/Corefile:ro
- ./host.conf:/config/host:ro
127.0.0.1 www.mygoogle.com
127.0.0.1 www.mygoogle2.com
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment