I had the same problem as you as I was starting with this as well on debian trixie. What finally worked was this.
I think you should
disable the systemd-resolved stub listener. This is done by setting DNSStubListener=no
change /etc/resolve.conf to point to run/systemd/resolve/resolv.conf instead of the stub.
This should remove the 127.0.0.53 naneserver and put the real one in it.
From the man pages
systemd-resolved maintains the
/run/systemd/resolve/resolv.conf file for compatibility with
traditional Linux programs. This file may be symlinked from
/etc/resolv.conf and is always kept up-to-date, containing
information about all known DNS servers. Note the file
format’s limitations: it does not know a concept of
per-interface DNS servers and hence only contains system-wide
DNS server definitions. Note that
/run/systemd/resolve/resolv.conf should not be used directly
by applications, but only through a symlink from
/etc/resolv.conf.
I had the same problem as you as I was starting with this as well on debian trixie. What finally worked was this.
I think you should
This should remove the 127.0.0.53 naneserver and put the real one in it.
From the man pages
systemd-resolved maintains the /run/systemd/resolve/resolv.conf file for compatibility with traditional Linux programs. This file may be symlinked from /etc/resolv.conf and is always kept up-to-date, containing information about all known DNS servers. Note the file format’s limitations: it does not know a concept of per-interface DNS servers and hence only contains system-wide DNS server definitions. Note that /run/systemd/resolve/resolv.conf should not be used directly by applications, but only through a symlink from /etc/resolv.conf.
My 2 cents