move /etc/hosts logic into pipaddr