added ability to find machine ports from hostname