Reusable Development Environments on a VM Part 1: Setting Up the DNS to Work Properly on Mac OSX

1 min read
Reusable Development Environments on a VM Part 1: Setting Up the DNS to Work Properly on Mac OSX

Image Credit: Mike Minecki and chatGTP

When running local development on a virtual machine, adding a new site means manually editing your /etc/hosts file every time — because Mac OSX doesn’t support wildcard entries like *.local. This tutorial walks through setting up a BIND DNS server on your Mac to solve that problem, so that any new subdirectory you create on your VM automatically becomes a resolvable local domain. The guide covers editing named.conf, creating zone files, generating the required keys, starting the daemon, and verifying everything works with dig and ping. If you’re tired of manually managing hosts entries for local development, read the full article.

Suggest an edit

Last modified: 11 Feb 2026