Skip to content

Pi-hole static DNS entry

This is more docker related but should be similar to just a plain jane install. You can add your static entries to the /etc/hosts file or you can add it the the dnsmasq.d configuration file.

Create a file under /etc/dnsmasq.d, something like myhosts.conf and add the following. Keep adding entries until your done.

host-record=hostname.com,192.168.1.1

Find your pi-hole dns configuration under /etc/dnsmasq.d. Open the file and add the following line to end of your the configuration file.

conf-file= /etc/dnsmasq.d/ myhosts .conf

Go back to the pi-hole GUI and restart the DNS under settings/system “restart DNS resolver”.

Hits: 0

Published inLinuxUNRAID

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.