Merged requested to merge ee-clean-up-project-for-merge-conflicts into master
This is the EE version of MR https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/11967. It includes the changes of said MR along with moving all EE specific code (except for some
prepend calls) to separate concerns. This should ensure the model is almost identical for both CE and EE, reducing the number of merge conflicts.