Integration Guide

gitlab logo Integration1 Jira Server

Acquiring URL

This process requires an existing GitLab git repository.  For starters, the GitLab repository URL can be acquired on the repository project page.  Choose between SSH or HTTPS.

GitLab repository home

Use this information to connect the GitLab git repository to your Jira server via Git Integration for Jira add-on: Manage Git Repositories > Connect to Git Repository.

helpful tip
The Git Integration for Jira add-on supports v3 and v4 of the GitLab API (in both Jira Cloud and Jira Server).

Connecting to a Account

This process requires an existing account.  Multiple git repositories in a account will be connected via Git Integration for Jira add-on.

GitLab introduced personal access tokens (PAT) since version 8.8 and now (v10+) prefers this type of authentication for accessing the git repositories.  Service users are strongly advised to switch from using username/password to using Personal Access Tokens (PAT) for

While instructions from GitLab works just fine, here are some specific instructions to get you up and running.

Creating a Personal Access Token

  1. Login to your GitLab account then go to your Profile Settings.
  2. Select Access Tokens on the sidebar.  The following screen is displayed:
  3. GitLab MFA generate access token
  4. Give the token a descriptive name. (For example, "Git Integration for Jira")
  5. Leave the Expires at field blank.
  6. Select the "api" scope.
  7. Click Create personal access token.
  8. Copy the token – (Write it down or be sure to save it. This is the ONLY time you'll see the token).

Connecting Git Repositories to Jira Server

  1. Go to Manage Git Repositories (Dashboard > Git menu) in Jira Server.
  2. Click GitLab in the Auto-connect integration panel.
  3. is selected by default.  Paste the personal access token in the provided field.
  4. Connect to Authentication screen
  5. Follow instructions in the wizard to import GitLab repositories.

There will be a slight delay in adding this repository compared to others.  It will show in the git configuration list eventually.

helpful tip
Admin/Power Users:
To pass the private access token (for example: XpigzF1JxMnAZ7mn9qgN) to an API call with
curl --header "Private-Token: XpigzF1JxMnAZ7mn9qgN"
helpful tip
In order to access a Git repository over HTTP, use the username as the username and the PAT for the password.