Validate port sets

Allocate ports, both statically specified and dynamically allocated, in discrete sets.  If any individual allocation fails then the entire allocation fails without any effects. 

This addresses issue #57 and issue #59.  It also fixes potential race/deadlock issues with container allocation related to port allocation.

Okay... but I don't really understand why you'd impose artificial restrictions into a simple and general-purpose function like that.