This project implements a simple DNS resolver in Go using the net
package. The resolver takes a hostname as input and returns the IP addresses associated with that hostname.
- Resolves A records for a given hostname.
- Command-line interface for easy usage.
- Basic error handling and logging.
- Go 1.18 or higher installed on your machine.
-
Clone the repository:
git clone https://github.com/rahul1804/dns-resolver.git cd dns-resolver
-
Initialize the Go module:
go mod init dns-resolver
To build the DNS resolver application, run the following command:
go build -o dns-resolver
./dns-resolver google.com