Gitlab

How to connect your Github account with Village Labs.

Prerequisites

  • A Gitlab account with access to the repositories you wish to sync with Village Labs.

  • Depending on the configuration, either a Free or a Premium/Ultimate Gitlab plan

Generating the credentials

  1. You can generate a personal access token at https://gitlab.com/-/user_settings/personal_access_tokens

  2. Click 'Add new token'

  3. Do not enter an expiration date, as you'll need to reconnect once it expires. You can always revoke Village Labs' access to this token in future if required.

  4. Select the required scopes:

    api

  5. Next click 'Create personal access token' and copy / save your token.

Note: Village will only read, and not write data from your Gitlab instance. The only reason why an api, and not read_api scope is required is because, during the connection's setup, a webhook is configured to push real-time updates from Gitlab to Village's infrastructure.

Information required for the Village connection:

  • access_token: The access token created above

  • groups_list: A comma-separated (no spaces) list of the group ids which should be synchronized. If left empty, Village will synchronize all groups that this access token can read

    • This requires a Gitlab Premium/Ultimate/Self-managed instance

  • projects_list: A comma-separated (no spaces) list of the projects (or repositories) that should be synchronized. If left empty, Village will synchronize all projects that can be accessed (or within the groups configured above)

    1. Premium Tiers: If you wish to synchronize all repositories (projects) under a group (see config below), a Gitlab Premium/Ultimate/Self-managed instance is required: data will be (in part) synchronized through group hooks, which are not available in the Free Tier.

    2. Free Tier: If you have a Free Tier Gitlab instance, you will need to provide an explicit list of the projects to synchronize: the data will be synchronized (in part) through project hooks.

  • start_date: Date of the first record to synchronize, in the following format: 2024-01-01T00:00:00Z . Commits before this date will not be synchronized.

Last updated