Installing the GitLab App

The GitLab app collects data from two sources:

  • GitLab webhooks generate real-time data for issues, merge requests, jobs, pipelines, and commits.

  • The Observe poller for GitLab periodically collects metadata about issues, groups, users, merge requests, runners, and projects.

Use the following sections to install and configure the collectors to send data to Observe. For more about exploring this data, see GitLab.

Setup

Install the GitLab app using the Apps tab in Workspace Settings.

GitLab app installation page

Figure 1 - GitLab App Configuration

Webhook Configuration

A webhook linked to your GitLab group pushes data to Observe as new activity happens. The GitLab app ingests data for these sources:

  • Activity Dashboard

  • Administration Dashboard

  • Commit Dataset

  • Issue Dataset

  • Job Dataset

  • Merge Request Dataset

  • Pipeline Dataset

To configure the webhook:

  1. Navigate to the home page of your group on GitLab.

  2. Hover over Settings in the left toolbar and click Webhooks.

GitLab home page for a Group, showing the tabs for Group management.

Figure 2 - GitLab Group Home Page

If you don’t see the Settings tab, you may not have administrative permissions for your organization. Contact a group administrator to confirm your permissions.

3. In the Settings menu, click Webhooks.

4. Configure the following settings:

  • URL: https://${OBSERVE_TOKEN?}@${OBSERVE_CUSTOMER?}.collect.${OBSERVE_DOMAIN?}/v1/http/gitlab

    • Choose Mask portions of URL and mask the OBSERVE_TOKEN

  • Triggers:

    • Push events

      • All branches

    • Comments

    • Confidential comments

    • Issues events

    • Confidential issues events

    • Merge request events

    • Job events

    • Pipeline events

    • Deployment events

  • Select Enable SSL verification

GitLab app webhook setup page on the GitLab website.

Figure 3 - GitLab Webhook Configuration Page

5. Click Add webhook to save your configuration.

For more about GitLab webhooks, see Creating webhooks in the GitLab documentation.

Configuring the GitLab poller

Pollers periodically request data from the GitLab API, allowing ingestion of existing details without a triggering event. The Observe GitLab poller ingests data about these sources:

  • Administration Dashboard

  • Issue Dataset

  • Group Dataset

  • Merge Request Dataset

  • Runner Dataset

  • Project Dataset

To configure the GitLab poller:

  1. In the GitLab app, go to the Connections tab.

  2. Under Data connection requirements, in the Onboard GitLab poller event section, click Create connection.

  3. In the Create poller dialog, configure the following settings:

    • For GitLab Group, enter the name of your GitLab group.

    • For GitLab Token, create a GitLab group access API token associated with the GitLab group dedicated to poller data, and paste the token into Observe.

Your GitLab API token should have the following permissions using the Owner role:

  • read_api

  • read_repository

  • read_registry

GitLab poller configuration page on the GitLab website.

Figure 4 - GitLab Group Access Token Page

GitLab poller configuration page on the Observe website.

Figure 5 - GitLab Poller Configuration Page

You have now configured the GitLab app to send GitLab data to Observe.