summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--etc/NetworkManager/conf.d/NetworkManager.conf3
-rw-r--r--etc/resolvconf.conf11
2 files changed, 8 insertions, 6 deletions
diff --git a/etc/NetworkManager/conf.d/NetworkManager.conf b/etc/NetworkManager/conf.d/NetworkManager.conf
index aceb13f0..4f325819 100644
--- a/etc/NetworkManager/conf.d/NetworkManager.conf
+++ b/etc/NetworkManager/conf.d/NetworkManager.conf
@@ -1,5 +1,4 @@
-# If set dns=none and use mullvad vpn, /etc/resolv.conf will have a `search xxx.yyy` line at the end. I don't know why but it seems that line is needed to resolve and connect to xxx.yyy.
-# If not set dns=none and not use mullvad vpn, NetworkManager will copy router's DNSes to /etc/resolv.conf and overwirte it which I don't want. There's multiple ways to prevent it: set immutable file attribute, dns=none in NetworkManager.conf, or /etc/resolv.conf.head and /etc/resolvconf/resolv.conf.d/head (need resolvconf?). I only tested dns=none way. The weired thing is in this case `search xxx.yyy` is not needed to reach xxx.yyy
[main]
# https://wiki.archlinux.org/title/NetworkManager#Unmanaged_/etc/resolv.conf
dns=none
+rc-manager=resolvconf
diff --git a/etc/resolvconf.conf b/etc/resolvconf.conf
index 4f5f2e6f..66534b26 100644
--- a/etc/resolvconf.conf
+++ b/etc/resolvconf.conf
@@ -1,7 +1,10 @@
# Configuration for resolvconf(8)
# See resolvconf.conf(5) for details
-resolv_conf=/etc/resolv.conf
-# If you run a local name server, you should uncomment the below line and
-# configure your subscribers configuration files below.
-#name_servers=127.0.0.1
+# https://wiki.archlinux.org/title/Dnsmasq#openresolv
+# Use the local name server
+name_servers="::1 127.0.0.1"
+resolv_conf_options="trust-ad"
+# Write out dnsmasq extended configuration and resolv files
+dnsmasq_conf=/etc/dnsmasq-conf.conf
+dnsmasq_resolv=/etc/dnsmasq-resolv.conf