Sleuth Documentation
HomeBlogSupportSign up
  • Getting started
  • Navigating Sleuth
  • DORA metrics
    • Deploy frequency
    • Change lead time
    • Change failure rate
    • MTTR
    • Interpreting Metrics in Sleuth
  • Deployment tracking
    • Organization
      • Labels
      • Trends
      • Compare
      • Search
      • Status
    • Projects
      • Issue trackers
    • Environments
    • Code deployments
      • Creating a deployment
      • How to register a deploy
      • Rollbacks
      • Automatic tagging
      • Deployment locking
      • Environment drift
      • Move code deployments
      • Search everything
    • Feature flags
    • Manual changes
    • Deploys
    • Teams
  • Work in Progress
  • Goals
  • Sleuth Automations
    • Automations Marketplace
      • Installing Automations
        • Installing PR "Update" Automations
      • Editing and uninstalling Automations
      • Smart suggestions
      • Understanding efficacy
    • Custom Automations
      • Automations Cookbook
      • Webhook Actions
      • Trigger Build Actions
        • Bitbucket Pipelines
        • CircleCI
        • Github Actions
        • Jenkins
  • Slack & Email Notifications
  • Auto-verify deploys
    • Anomaly detection
    • Error impact
    • Metric impact
  • Ignoring pull requests
  • Slack mission control
    • Approvals
    • Project notifications
    • Personal notifications
    • Search Sleuth in Slack
    • Project/Deployment history
    • Developer standup
  • Sleuth API
    • Deploy Registration
    • Deploy import
    • Manual Change
    • Custom Incident Impact Registration
    • Custom Metric Impact Registration
    • Deprecation information
    • GraphQL Queries
    • GraphQL Mutations
    • Query batching
  • Integrations
    • About Integrations...
    • Code integrations (read-only)
      • Azure DevOps
      • Bitbucket
      • GitHub
      • GitLab
      • Custom Git
      • Terraform Cloud
    • Code integrations (write)
    • Feature flag integrations
      • LaunchDarkly
    • Impact integrations
      • Error trackers
        • Bugsnag
        • Honeybadger
        • Rollbar
        • Sentry
      • Metric trackers
        • AppDynamics
        • AWS CloudWatch
        • Custom
        • Datadog
        • Jira metrics (Cloud / Data Center)
        • NewRelic
        • SignalFx
      • Incident tracker integrations
        • Blameless
        • PagerDuty
        • Datadog Monitors
        • Statuspage
        • Opsgenie
        • Jira (Cloud/Data Center)
        • FireHydrant
        • Rootly
        • ServiceNow
        • Custom
          • Grafana OnCall
      • CI/CD builds
        • Azure Pipelines
        • Bitbucket Pipelines
        • Buildkite
        • CircleCI
        • GitHub Actions
        • GitLab CI/CD Pipelines
        • Jenkins
    • Sleuth DORA App for Slack
    • Microsoft Teams integration
    • CI/CD integrations
      • Azure Pipelines
      • Bitbucket Pipelines
      • Buildkite
      • CircleCI
      • Github Actions
      • GitLab CI/CD Pipelines
      • Jenkins
    • Issue tracker integrations
      • Jira Cloud
      • Jira Data Center
      • Linear
      • Shortcut
    • Fixing broken integrations
  • Pulse
    • Welcome to Pulse docs
    • Quick Start setup guide
    • Beginner tutorials
      • 1. How to create a Teamspace
      • 2. How to create a Review
      • 3. How to create a Survey
  • Features
    • Reviews
      • Review workflow
      • Review templates
      • Widgets and Sections
        • Widget type
      • Review settings
    • Surveys
      • Survey Workflow
    • Teamspaces
    • Inbox
    • AI assistant
    • General settings
      • Users and Teams
      • Investment mix
  • Settings
    • Organization settings
      • Details
      • Authentication
        • SAML 2.0 Setup
          • Okta Configuration
          • Azure AD Configuration
          • PingIdentity Configuration
      • Access Tokens
      • Members
      • Team Settings
      • Billing
    • Project settings
      • Details
      • Slack settings
      • Environment settings
      • Code deployment settings
      • Feature flag settings
      • Impact settings
    • Account settings
      • Account settings
      • Notifications settings
      • Identities settings
    • Role Based Access Control
  • Resources
    • FAQ
    • Sleuth TV
    • Purchasing
    • About Sleuth...
Powered by GitBook
On this page
  • About the integration
  • Setting up the integration
  • Custom HTTP headers
  • Read-only mode
  • Configuring the integration
  • Removing the integration

Was this helpful?

  1. Integrations
  2. Code integrations (read-only)

GitLab

PreviousGitHubNextCustom Git

Last updated 2 years ago

Was this helpful?

About the integration

Integrating GitLab with Sleuth is simple. If you're connecting to a personal GitLab repo, you just need your credentials. If you're part of an organization and aren't the owner, you will need permission to allow Sleuth to connect to the repo—after you connect you'll be able to select individual private or public repositories.

Be sure your account has at least . We query for min_access_level=40

Check out this video by Sleuth CTO Don Brown on how to get started with Sleuth and GitLab

Setting up the integration

To set up the GitLab integration:

  1. Click Integrations in the left sidebar, then select Code in the dropdown at the top-right to filter the view.

  2. In the GitLab tile, click Enable.

  3. On successful integration, GitLab enabled will be displayed in the GitLab tile. You'll next configure the code deployment to connect your repo to a project.

Custom HTTP headers

If you using GitLab on-premise behind Cloudflare access or similar, Sleuth might need to include some HTTP headers in order to reach your instance. In order to set Sleuth to send any custom HTTP headers when making requests:

  1. In the GitLab dialog, click on the Advanced setting

  2. Enter comma separated list of custom headers you want Sleuth to include

Read-only mode

GitLab can be configured in read-only mode, making use of a read-only token from GitLab. Several Sleuth features such as deployment locking and some Sleuth Action automations may be disabled, but if your security team requires integrations to be read-only, this may be necessary.

  1. In the GitLab dialog, click on Advanced settings and check Read-only checkbox.

  2. Continue to add a new code deployment as usual.

  3. Copy the webhook URL, secret, and note the events for later

  4. Visit your GitLab repository settings and click on Webhooks

  5. Save the new webhook and now Sleuth should receive the required GitLab events.

Steps 3 through 7 need to be done for each GitLab repository

Configuring the integration

  1. After step #4 above, you will be taken back to the GitLab integration tile. On the GitLab tile, click the Add code deployment dropdown.

Removing the integration

If you wish to dissolve the GitLab integration for the organization:

  1. Click on Integrations in the left sidebar, then on Change Sources.

  2. In the GitLab integration card, click disable.

The GitLab integration is disconnected and no longer available to any projects within that organization.

You must grant Sleuth access to your GitLab account. Don't worry, you'll select the GitLab repo to connect to your Sleuth project later.

Now, you'll need to manually configure the GitLab webhook so that Sleuth is notified about key events. Visit the code deployment page, click on the cog at the top right and select Get webhook instructions \

Create a new webhook, using the URL and secret from the earlier dialog, and check the events that match with the requested list

You now need to add a for your GitLab repo to a Sleuth . Once configured and you start Sleuth will be tracking deploys for your code changes.To configure the GitLab integration:

Select the you wish to add a chance source to from the dropdown list.

Follow the instructions for

code deployment
project
registering deploys
Sleuth project
setting up a new code deployment
maintainer privileges