Skip to content

Support several instance for API calls

Rémy Coutable requested to merge support-several-instances-for-api-calls into master

What does this MR do and why?

This adds support to make API calls to different GitLab instances (for now we only support gitlab.com and dev.gitlab.org).

This is a prerequisite for #1380 (closed) where we'll need to fetch jobs from the dev instance.

TODO

  • Populate GITLAB_COM_API_TOKEN with the value of GITLAB_API_TOKEN
  • For now, I populated GITLAB_DEV_API_TOKEN with a personal token of mine, while we create a proper @gitlab-bot service account on dev
  • Create a proper @gitlab-bot service account on dev and replace the value of GITLAB_DEV_API_TOKEN with a personal token from it

Expected impact & dry-runs

These are strongly recommended to assist reviewers and reduce the time to merge your change.

See https://gitlab.com/gitlab-org/quality/triage-ops/-/tree/master/doc/scheduled#testing-policies-with-a-dry-run on how to perform dry-runs for new policies.

See https://gitlab.com/gitlab-org/quality/triage-ops/-/blob/master/doc/reactive/best_practices.md#use-the-sandbox-to-test-new-processors on how to make sure a new processor can be tested.

Action items

Edited by Rémy Coutable

Merge request reports