在 Docker 容器中的自定义名字服务器

As far as I’m aware, the container’s resolv.conf is copied from the host. So, if the container host has Google’s nameservers, then that’s what the container will get. AFAIK, there’s no way for a container image, nor the command line, to override that behaviour. Of course, you can edit the container’s resolv.conf after it is started, but there’s nothing in the Discourse images to do that that I can find. Certainly, the discourse.org hosting, which uses the same images as are publically available, don’t override resolv.conf (it definitely gets copied in from the host).