[WIP] uniter: open-port and close-port now sandboxed and validated

An important improvement in supporting opening and
closing port ranges for charms is to also provide
sandboxing for these operations. This PR implements
an internal caching of all pending port ranges to
open or close for the unit, as well as existing ports
opened on the unit's assigned machine by other units.
Each time open-port or close-port is called, we validate
the given range against other existing ranges on the
machine and other pending ranges and returns errors
when there's a conflict. Ports are only actually opened
or closed when the current hook is committed.