GitHub provides hosting for software development and version control using Git.
Use the SEI GitHub integration to integrate SEI with GitHub.
SEI only ingests repositories from organizations. SEI doesn't ingest your personal repos or repos where you are a collaborator but not a member of the affiliated organization.
In other words, the owner of the GitHub personal access token that is associated with the integration must be a direct member of an organization for a repo to be ingested by SEI.
The SEI GitHub integration can use either OAuth or Personal Access Token authentication.
If you can't use OAuth, you must create a GitHub PAT to configure the SEI GitHub integration.
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.
Select the following permissions for your personal access token:
reposcopes, including the parent
reposcope. The top-level
reposcope is required for SEI to have the required visibility into your repos.
Copy the token somewhere that you can retrieve it when you configure the integration.
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.
Configure the integration
In your Harness project, go to the SEI module, and select Account.
Select Integrations under Data Settings.
Select Available Integrations, locate the GitHub Enterprise or GitHub Cloud integration, depending on your GitHub configuration.
Select an authentication method for the integration:
- To use OAuth, select Authorize and follow the prompts to grant access to GitHub.
- To use a personal access token, paste the token in Enter the Access Token.
In Integration Name, enter a name for the integration.
Select repositories to associate with the integration or select Ingest All Repos to associate all current and future repos in your GitHub organization.
If applicable, configure Additional Options:
- 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.
- Connect via GitHub webhook: Select this option if you want GitHub to push data to SEI through a webhook, rather than SEI pulling data from GitHub. This is an advanced configuration and only recommended if you are confident about using this configuration.
Finish configuration and save the integration.
If you created a personal access token and allowed the
admin:org_hook permission, SEI creates a user webhook to receive issue cycle time data for the SCM Issue Time Across Stages Report.
If you used OAuth, SEI creates an organization webhook instead.
The steps for configuring the integration using Satellite is similar to configuring the integration on cloud, with the exception of using satellite to communicate with the Github server.
Make sure to select the satellite integration checkbox while configuring the integration.
Here’s a sample
url: 'https://app.harness.io/gratis/sei/api' # Note that this URL is relative to the environment you are using.
- id: '<INTEGRATION_ID>'
- apikey: <GITHUB_PAT>
If you encounter any issues during the integration process, go to the Satellite integration Troubleshooting and FAQs.