Configuration
Customize NexoralDNS to fit your needs. Most settings can be configured through the dashboard or environment variables.
Dashboard
Most settings can be configured directly from the web dashboard at localhost:4000. Changes take effect immediately.
Environment Variables
For advanced users, configure NexoralDNS via environment variables in the Docker Compose file or .env file.
đDNS Settings
Upstream DNS Providers
Configure which DNS servers to use for resolving external domains. NexoralDNS forwards queries it can't resolve locally to these providers.
1.1.1.1Fast & privacy-focused
8.8.8.8Reliable & fast
9.9.9.9Security-focused
208.67.222.222Family-friendly options
Configure in Dashboard â Settings â DNS Providers
DNS Port
By default, NexoralDNS listens on port 53 (standard DNS port). You can change this if needed.
DNS_PORT=53â ī¸ Changing from port 53 requires additional router configuration.
Cache Settings
Control how long DNS responses are cached. Longer TTL = fewer upstream queries, but slower updates.
300 seconds (5 min)10,000 entries60 secondsđ§Environment Variables
| Variable | Default | Description |
|---|---|---|
DNS_PORT | 53 | Port for DNS server |
WEB_PORT | 4000 | Port for web dashboard |
UPSTREAM_DNS | 1.1.1.1 | Primary upstream DNS |
CACHE_TTL | 300 | Default cache TTL in seconds |
LOG_LEVEL | info | Logging level (debug, info, warn, error) |
REDIS_URL | redis://localhost:6379 | Redis connection URL |
DB_PATH | /data/nexoraldns.db | Database file path |
ENABLE_ANALYTICS | true | Enable query analytics |
đŗDocker Compose Example
Customize your deployment by modifying the Docker Compose file:
version: '3.8'
services:
nexoraldns:
image: nexoral/nexoraldns:latest
ports:
- "53:53/udp"
- "53:53/tcp"
- "4000:4000"
environment:
- UPSTREAM_DNS=1.1.1.1
- CACHE_TTL=300
- LOG_LEVEL=info
- ENABLE_ANALYTICS=true
volumes:
- nexoraldns-data:/data
restart: unless-stopped
volumes:
nexoraldns-data:đSecurity Settings
Dashboard Authentication
The dashboard is protected by authentication. Change the default password immediately after installation via Dashboard â Settings â Security.
API Authentication
API requests require an API key. Generate keys in Dashboard â Settings â API Keys. Use the key in the Authorization header.
Rate Limiting
Enable rate limiting to prevent DNS amplification attacks. Configure max queries per IP in Dashboard â Settings â Security.
đĄPro Tips
- âĸBack up your configuration before making major changes
- âĸUse multiple upstream DNS providers for redundancy
- âĸMonitor query logs after configuration changes to ensure everything works
- âĸKeep your NexoralDNS installation updated for security patches