Refactoring to move server related code and files to it's own folder