DPS actually is fully supported on MAC knowing docker limitation features. Despite on this, there is no additional configuration to run DPS on Mac, you can do just like on Linux.
Download the latest release, extract and run:
$ sudo ./dns-proxy-server
Check this for usage samples.
When running on standalone mode (not on docker container) DPS will be able to auto configure itself as OSX default DNS,
after 5 seconds you see something like usingDnsConfigurator=DnsConfiguratorOSx
at the logs.
It’s also possible to run DPS on docker you can do it in different ways, bellow the most recommended.
(todo: Explain)
When not running in standalone mode you will need to configure DPS as default DPS manually, check the instructions bellow:
To list available networks:
$ networksetup -listallnetworkservices
An asterisk (*) denotes that a network service is disabled.
USB 10/100/1000 LAN
Wi-Fi
Thunderbolt Bridge
In my case the right Network is Wi-Fi
, before change anything let’s check if it has some manual
configured DNS server:
$ networksetup -getdnsservers Wi-Fi
There aren't any DNS Servers set on Wi-Fi.
If it returns some server IP then is a good idea to backup it then you can restore the configurations later.
Let’s set DPS as the default DNS Server, best option here is to get your network IP address, Wi-Fi
in my case which
has 192.168.0.14
set, 127.0.0.1
will partially works because this way containers won’t be able
to solve each other in my tests.
Obs: Be aware you need to run DPS in port 53 as MAC doesn’t accept custom port especification.
$ networksetup -setdnsservers Wi-Fi 192.168.0.14
If you need to remove the configured DNS server then it will use your network provider DNS
$ networksetup -setdnsservers Wi-Fi Empty
See this thread with more use cases.