convert hosts file format into dnsmasq config format