Name resolving has everything to do with the docker network used in this case. The dns resolver is defined as "127.0.0.11" in the user's config as posted above (also as such in the preset proxy confs we provide), which is docker's resolver. If both containers are in a "user defined bridge network", that resolver will resolve container names and aliases to container IPs used in that "user defined bridge network". There is no such resolution in the default docker bridge network. Also fyi, you can simply not set any network in the container creation arguments and docker by default will use the default bridge. And when a container connects to another container via the docker bridge network IP, it should use the container port, not the host port mapped as saarg wrote.
Either you are confused, or you are arguing semantics for the sake of arguing. In any case, you are not being helpful.