Allow more flexibility when setting ports