A local DNS server, used to test Cloudflare CDN latency and speed, get the fastest IP (IPv4).一个本地DNS服务器, 用于测试 Cloudflare CDN 延迟和速度,获取最快 IP (IPv4 )。支持docker一键部署。
测试Cloudflare CDN 延迟,获取最快的IPV4。
内置DNS服务, 无需手动改Hosts文件。
cd ~/;mkdir -p cfdns/conf && cd cfdns
wget https://raw.githubusercontent.com/ClassmateLin/cfdns/main/conf/config.toml -O ./conf/config.toml
wget https://raw.githubusercontent.com/ClassmateLin/cfdns/main/conf/ip.txt -O ./conf/ip.txt
docker run -itd -e RUST_LOG=info -v ~/cfdns/conf:/usr/local/cfdns/conf -p 9053:53/udp --name cfdns classmatelin/cfdns
docker logs cfdns
dig @127.0.0.1 -p 9053 www.cloudflare.com
见: [lazy-docker](https://github.com/ClassmateLin/lazy-docker/blob/main/docker-compose.dns.yml
RUST_LOG=info ./cfdns
请确保您已正确安装了Rust.
git clone https://github.com/ClassmateLin/cfdns.git && cd cfdns
cargo build --release
, 编译结果在./target/release
目录下。
├── cfdns
└── conf
├── config.toml
└── ip.txt
RUST_LOG=info ./cfdns
运行: