Quick Start
This guide will help you get started with DNS CLI in just a few minutes.
DNS Client
Basic Query
Query a domain's A record:
bash
dns client lookup google.com --type AQuery IPv6
Query a domain's AAAA record (IPv6):
bash
dns client lookup google.com --type AAAAUse DoT Server
Query using DNS-over-TLS:
bash
dns client lookup example.com --server tls://1.1.1.1Plain Output
Get only IP addresses (useful for scripting):
bash
dns client lookup google.com --plainDNS Server
Start Basic Server
Start a DNS server on port 53:
bash
dns server --port 53Start with Custom Upstream
Start a DNS server with custom upstream DNS servers:
bash
dns server --port 53 --upstream 8.8.8.8:53 --upstream 1.1.1.1:53Start with Configuration File
Create a configuration file config.yaml:
yaml
server:
port: 53
hosts:
"example.com": "1.2.3.4"
"*.example.com": "1.2.3.4"
upstream:
servers:
- "8.8.8.8:53"Start the server:
bash
dns server --config config.yamlNext Steps
- Client Usage - Learn more about DNS client features
- Server Usage - Learn more about DNS server features
- Configuration - Learn about configuration options