Throw an exception if the serve command fails