Stability fixes

Added dynamic ports for the servers.
Added reconnection code to workers.
Split server into upload/distribution servers.