https://github.com/luciangutu/go_wildcard_dns
A simple wildcard DNS server written in Go.
https://github.com/luciangutu/go_wildcard_dns
dns-server golang
Last synced: 3 months ago
JSON representation
A simple wildcard DNS server written in Go.
- Host: GitHub
- URL: https://github.com/luciangutu/go_wildcard_dns
- Owner: luciangutu
- Created: 2024-09-07T15:29:38.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-09-07T15:32:54.000Z (9 months ago)
- Last Synced: 2025-01-10T21:12:45.849Z (5 months ago)
- Topics: dns-server, golang
- Language: Go
- Homepage:
- Size: 1.95 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Go Wildcard DNS Server
A simple wildcard DNS server written in Go. This server responds with a configurable A record for any DNS query.
### Features
- Wildcard DNS server
- Configurable A record IP address### Prerequisites
- Docker
- Go### Build the container
```shell
docker build -t wildcard-dns-server .
```### Run the server
Run the container with the desired IP address for A records.
Replace `192.168.100.1` with the IP address you want the server to respond with for A records.
The DNS server will listen on port 53 for UDP queries and respond with the specified IP address for any query.
```shell
docker run --rm --name dns-server wildcard-dns-server 192.168.100.1
```### Example usage
Query the DNS server using dig or another DNS client (replace localhost with the container IP):
```shell
dig @localhost example.com
```### Loadtesting
`queries.txt` content
```shell
example.com A
test.example.com A
```Run the loadtest for 60 seconds.
```shell
dnsperf -s -d queries.txt -l 60
```