Move import rake task classes into a service
<!--IssueSummary start-->
<details>
<summary>
Everyone can contribute. [Help move this issue forward](https://handbook.gitlab.com/handbook/marketing/developer-relations/contributor-success/community-contributors-workflows/#contributor-links) while earning points, leveling up and collecting rewards.
</summary>
- [Close this issue](https://contributors.gitlab.com/manage-issue?action=close&projectId=278964&issueIid=341960)
</details>
<!--IssueSummary end-->
The following discussion from !71402 should be addressed:
- [ ] @dstull started a [discussion](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/71402#note_690454033): (+1 comment)
> A lot of code in here that is hard to test due to placement in a rake task and reduces the ability to DRY up the code with other areas...
>
> Should we spawn a follow-up to discuss moving the classes defined in here to a more testable area like services?
issue