Skip to content

Libbehave CI component doesn't work on self-hosted GitLab instances

The libbehave CI component (this repository) doesn't work correctly on self-hosted GitLab instances. When the analyzer binary attempts to create the MR comment, it fails because the API endpoint is hardcoded to https://gitlab.com/. This, of course, fails since self-hosted instances use their own domain.

I pulled down the binary and poked around, but couldn't find any way to override the API connection without a code change. Is this something that could be fixed?

(btw I know this should be filed against the analyzer component, but that repository is private and I don't have access to view it or open an issue.)

Here's an example error from the logs:

5:40AM INF adding MR comment with results mr_id=1232
libbehave: No new packages detected5:40AM INF could not find libbehave merge request note, adding new note error="fetching notes for issue 1232 (project ID: 1): GET https://gitlab.com/api/v4/projects/1/merge_requests/1232/notes: 401 {message: 401 Unauthorized}"
5:40AM WRN failed to create MR note error="POST https://gitlab.com/api/v4/projects/1/merge_requests/1232/notes: 401 {message: 401 Unauthorized}"
Edited by Hazelnoot