If you are using GitLab CI, you can analyze your source code quality using the Code Climate analyzer Docker image. Going a step further, GitLab can show the Code Climate report right in the merge request widget area.
In order for the report to show in the merge request, you need to specify a
codeclimate job (exact name) that will analyze the code and upload the resulting
codeclimate.json as an artifact. GitLab will then check this file and show
the information inside the merge request.
For more information on how the
codeclimate job should look like, check the
example on analyzing a project's code quality with Code Climate CLI.