loop through hosts