If you want to enable DNS by setting up a /etc/resolv.conf file, add DNS to your hosts lines as shown below.
hosts: ldap dns [NOTFOUND=return] files