Refactor the method to init the liveserver.