Function to return nodes ips.