function sanitizePort(port) {
            port = parseInt(port, 10);
            port = (port && !isNaN(port) && port > 0 && port < 65536) ? port : 0;
            return port;
        }
Gets the server details from the StaticServerDomain in node.
The domain itself handles starting a server if necessary (when
the staticServer.getServer command is called).

@return {jQuery.Promise} A promise that resolves/rejects when
    the server is ready/failed.