refactoring of on-up-script. getting hosts from peer-files