Skip to main content

Day 152

 14/08/2020 Friday, Rainy 

Below shows how to block a batch websites using wildcard in the domain names.

DNSMASQ

Install dnsmasq on macOS with homebrew:

~ brew install dnsmasq

 To configure dnsmasq, take the default example configuration at

/usr/local/etc/dnsmasq.conf and edit to taste. 
For individual users
~ vim /usr/local/etc/dnsmasq.conf

# This file will be added to the configuration
conf-file=/Users/your_user_name/.dnsmasq/dnsmasq.conf
~ vim /Users/your_user_name/.dnsmasq/dnsmasq.conf

# example.localhost will be resolved as 127.0.0.1, including subdomains
address=/example.localhost/127.0.0.1
listen-address=127.0.0.1
~ sudo brew services stop dnsmasq

~ sudo brew services start dnsmasq
 

Comments

Popular posts from this blog

Day 118

11/07/2020 Saturday, Cloudy For the 2nd time since lockdown, we got out of the house and went to the park as a family. Sean and I played table tennis there, while Lili jogged around the tennis court. Later we walked around the reservoir and came home from the high street. Though we've lived here for 5 years, it's the first time we walked around it. It's near 3 miles and we ended up exhausted.

Day 128

21/07/2020 Tuesday, Cloudy Sean is grounded for a whole day today. No screen time at all. Suprisingly he did well and repaired the relationship with his mum. Without computer, iPad or TV, he played piano, learnt Chinese and played TT. The only thing missed is the math exercise. Without anybody being grumpy, it's happy family again.