Configure the Git Integration to use self-managed GitLab (Beta)

Configure the Git integration for self-managed GitLab.

The Git Integration has beta support for a self-managed GitLab installation deployed on-premises or in the cloud. SnapLogic provides an app gateway, a secure transparent proxy, to route Git requests through your Groundplex to the GitLab server, providing an additional layer of security.

To enable use of self-managed GitLab for tracking SnapLogic assets, you need the following:

  • A subscription for the SnapLogic Git Integration
  • Administrative permission for the GitLab group
  • SnapLogic Environment (Org) admin permission
Important: Ensure that the network idle timeout on the GitLab service is more than 20 seconds. A timeout of 20 seconds or less can lead to connection errors for API calls.

Create application in GitLab

To enable GitLab to track SnapLogic assets, a GitLab administrator must create an application that configures connectivity:

  1. Log in to GitLab.
  2. Navigate to your Group.
  3. Select Settings.
  4. Click Applications.
  5. Click Add a new application.
  6. Enter a name.
  7. Specify these values:
    • For Redirect URI, enter: https://control-plane-name.snaplogic.com/api/1/rest/asset/app/oauthcallback
      Where control-plane-name is the control plane you are using. For example:
      • elastic
      • uat
      • emea
      Important: This Redirect URI is the same as the Callback URL that you specify to configure the Git Integration in your SnapLogic environment/org.
    • Leave the Confidential box checked.
    • For Scopes select the following:
      • api
      • read_api
      • read_user
      • write_repository
    • Click Save application.
    • Click the application to view it and copy the secret to use when configuring your SnapLogic Org.

Configure the SnapLogic Environment

To finish the configuration, a SnapLogic Environment admin must configure Git Integration settings:

  1. Open the Classic Manager.
  2. From the left panel select Settings.
  3. Scroll down to Git Integration and click Configure Git.
  4. From the Git Integration Type dropdown list, select GitLab on-premises. The configuration dialog opens:
    Configure GitLab

  5. Enter the following values:
    1. App ID: The Application ID from the GitLab application.
    2. Client Secret: The Secret copied from the GitLab application.
    3. Gitlab URL: The app gateway URL in the format: org-location-environment-appname.control-plane-name.
    4. Auth URL: The URL for your GitLab server.
    5. Http proxy: The HTTP proxy.
    6. Https proxy: The HTTPS proxy.
    7. Authorized scopes: api read_api read_user write_repository
    8. Callback URL: The Redirect URI from the GitLab application, https://control-plane-name.snaplogic.com/api/1/rest/asset/app/oauthcallback.
      Where control-plane-name is the control plane you are using. For example:
      • elastic
      • uat
      • emea
      Important: This Callback URL is the same as the Redirect URI that you specified in the GitLab application.
  6. Click Save.
  1. Open Admin Manager.
  2. From the left navigation panel under System Configurations select Git Integration.
  3. From the Git integration type dropdown list, select GitLab on-premises. The configuration page opens:
    Configure GitLab

  4. Enter the following values:
    1. App ID: The Application ID from the GitLab application.
    2. Client secret: The secret copied from the GitLab application.
    3. Gitlab URL: The app gateway URL in the format: org-location-environment-appname.control-plane-name:port-number. For example, with an environment named test and a Groundplex with an Environment value of dev, the gateway URL would be as follows:

      https://test-sidekick-dev-gitlab.appgateway.prod.snaplogic.io:8095

    4. Auth URL: The URL for your GitLab server.
    5. Http proxy: The HTTP proxy.
    6. Https proxy: The HTTPS proxy.
    7. Authorized scopes: api read_api read_user write_repository
    8. Callback URL: The Redirect URI from the GitLab application, https://control-plane-name.snaplogic.com/api/1/rest/asset/app/oauthcallback.
      Where control-plane-name is the control plane you are using. For example:
      • elastic
      • uat
      • emea
      Important: This Callback URL is the same as the Redirect URI that you specified in the GitLab application.
  5. Click Save.

Configure the Groundplex

Configure the Groundplex to connect to the app gateway in Classic Manager or Admin Manager.

From Classic Manager:

  1. Select the Project associated with the Groundplex.
  2. Search for the Groundplex.
  3. Click it to open the Update Snaplex dialog.
  4. Click the Node Properties tab.
  5. In the Global Properties section, click Plus Icon to add the gateway key-value pair:
    On-premises Git configuration on Snaplex Node Properties tab

  6. Enter the appropriate values for the app gateway:
    • Key: jcc.app.gateway.gitlab
    • Value: https://org-location-environment-appname.controlplanename:port where:
      • org: The environment name.
      • location: The location of your Groundplex. Always sidekick.
      • environment: The value in the Environment field in your Groundplex Snaplex Settings tab.
      • appname: gitlab.
      • controlplanename: The control plane that hosts your environment and the app gateway port number:
        • Production: appgateway.prod.snaplogic.io:8095
        • UAT: appgateway.uat.snaplogic.io:8095
        • EMEA: appgateway.emea.snaplogic.io:8095
    • For example, with an environment named test and a Groundplex with an Environment value of dev, the gateway URL for self-managed GitLab would be as follows:

      https://test-sidekick-dev-gitlab.appgateway.prod.snaplogic.io:8095

From Admin Manager:

  1. In the left pane, click Snaplexes.
  2. Click the Groundplex to open the Update Snaplex page.
  3. Click the Node properties tab.
  4. In the Global properties section, click + Add new global property to add the gateway key-value pair:
    On-premises Git configuration on Snaplex Node Properties tab

  5. Enter the appropriate values for the app gateway:
    • Key: jcc.app.gateway.gitlab
    • Value: https://org-location-environment-appname.controlplanename:port where:
      • org: The environment (Org) name without hyphens (-). For example: myenterprise-snap-test should be passed as myenterprisesnaptest.
      • location: Location of your groundplex. Always sidekick.
      • environment: The value in the Environment field in your Groundplex Snaplex Settings tab.
      • appname: gitlab.
      • controlplanename: The control plane that hosts your environment and the app gateway port number:
        • Production: appgateway.prod.snaplogic.io:8095
        • UAT: appgateway.uat.snaplogic.io:8095
        • EMEA: appgateway.emea.snaplogic.io:8095

      For example, with an environment named test and a Groundplex with an Environment value of dev, the gateway URL for self-managed GitLab would be as follows:

      https://test-sidekick-dev-gitlab.appgateway.prod.snaplogic.io:8095