Skip to main content

Connect with GitHub Enterprise Server

GitHub Enterprise Server is a self-hosted version of GitHub designed for organizations that need to manage their repositories, code, and collaboration tools on their own infrastructure. To integrate Harness SEI with GitHub Cloud, go to Connect with GitHub Cloud.

Authenticate with GitHub

To create a GitHub personal access token to configure the SEI GitHub integration.

  1. Log in to your GitHub account and create a Personal Access Token. For instructions, go to the GitHub documentation on Managing your personal access tokens.

  2. Select the following permissions for your personal access token:

    • All repo scopes, including the parent repo scope. The top-level repo scope is required for SEI to have the required visibility into your repos.

    The repo scope selections for a GitHub personal access token.

    • The read:org scope under admin:org.

    The admin scope selections for a GitHub personal access token.

  3. Copy the token somewhere that you can retrieve it when you configure the integration.

  4. If your GitHub organization uses SAML SSO, enable SSO for your personal access token. For instructions, go to the GitHub documentation on Authorizing a personal access token for use with SAML SSO.

info

If you have enabled an allow list in your GitHub account, certain Harness IP addresses must be added to it in order to allow communication between the Harness Platform and GitHub. If the necessary IPs are not whitelisted, the integration may fail to authenticate or sync data properly.

To ensure your integration can work correctly, please refer to the list of Harness Platform IPs that may need to be whitelisted in your firewall.

Add the GitHub integration

To set up the integration for the GitHub Enterprise:

  1. Select Integrations under Data Settings.
  2. Select Available Integrations, locate the GitHub integration, and select Install.
  3. Select GitHub Enterprise as the integration type.
  4. Choose the Connect via Cloud option.

  1. Define the integration settings:
    • Integration Name: Name for your integration.
    • Description (optional): Add a description for the integration.
    • Tags (optional): Add tags for the integration if required.
  2. Configure the integration settings and authentication:
    • Add the PAT Key that you previously generated for your GitHub account. Note that you can add multiple PATs for the same integration.
    • Enter the URL of your GitHub Enterprise On-prem instance, for example, <https://GITHUB.ORGANIZATION-DOMAIN>. Ensure it's a valid URL.

  1. If applicable, configure the Additional Options.
    • Specify the repositories for which you want to ingest the data on SEI. Use the format username/repository-name. Leave this field blank to ingest all the repositories.
    • Specifically, select the fields that you want to include in the data ingestion.
      • Fetch PRs: Allow SEI to ingest PR data from GitHub.
      • Fetch Issues: Allow SEI to ingest data from GitHub Issues.
      • Fetch Projects: Allow SEI to ingest data from GitHub Projects.
      • Fetch Commits: Allow SEI to ingest commit metadata from GitHub.
      • Fetch Commit Files: Allow SEI to ingest data within commits from GitHub.
  2. Once you've configured the integration, click on Download YAML File to download the satellite.yml file.

See also