Configuring GitLab integration¶
REANA can integrate with any GitLab instance to provide continuous integration for workflows that are maintained inside Git repositories. By going to their REANA profile pages, users can enable the GitLab integration for the repositories they want, so that each change to one of them will automatically trigger the execution of a new workflow. If you are looking for documentation on how to use this feature, please have a look at the related Gitlab page.
Creating a new GitLab application¶
First of all, you will need to create a GitLab application. You can either create:
- a user-owned application, by selecting your avatar, then Edit Profile > Applications;
- a group-owned application, by going to the desired group, then Settings > Applications;
- an instance-wide application, by going to Admin Area > Applications.
There you will need to set the following values:
- Name will be the name of the GitLab app, for example
- Redirect URI should be set to the URL of the REANA instance followed by
/api/gitlab, for example
- Confidential should be selected;
- In Scopes, only
apineeds to be enabled.
To learn more about this, you can also check out GitLab's docs on how to create OAuth applications.
Configuring GitLab's secrets in REANA¶
After saving your application, GitLab will provide to you the client ID and the client secret of the application you have just created. You then need to pass these values to REANA, by setting the following Helm values:
secrets.gitlab.REANA_GITLAB_OAUTH_APP_IDshould be set to the client ID;
secrets.gitlab.REANA_GITLAB_OAUTH_APP_SECRETshould be set to the client secret;
secrets.gitlab.REANA_GITLAB_HOSTshould be set to the hostname of the GitLab instance you are using, for example
As an example:
secrets: gitlab: REANA_GITLAB_OAUTH_APP_ID: "<your-client-ID>" REANA_GITLAB_OAUTH_APP_SECRET: "<your-client-secret>" REANA_GITLAB_HOST: "gitlab.example.org"