-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Ghe integration #21929
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
cbehera-newrelic
wants to merge
16
commits into
develop
Choose a base branch
from
GHE-integration
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Ghe integration #21929
Changes from 1 commit
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
52f149b
wip
cbehera-newrelic a6a4ea2
wip
cbehera-newrelic 7dca6ef
wip
cbehera-newrelic fd35b6f
wip
cbehera-newrelic c4f0f41
wip
cbehera-newrelic 0ba5a33
Merge branch 'develop' into GHE-integration
cbehera-newrelic 88febe5
fixing merge conflicts
cbehera-newrelic 903de75
removed image
cbehera-newrelic c2a8f77
deleted unpaired translation
cbehera-newrelic 79b23fe
Fixed review comments
cbehera-newrelic be92db9
fixing merge conflicts
cbehera-newrelic c2b96f9
All review comments are addressed
cbehera-newrelic 46f78be
Updates to styes
cbehera-newrelic 168cd73
review comments are addressed
cbehera-newrelic b2f48c4
minor enhancements
cbehera-newrelic f1ea8be
Review comments are incorporated
cbehera-newrelic File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
review comments are addressed
- Loading branch information
commit 168cd73b90a79f630e13df8c319eb20607601839
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -14,9 +14,10 @@ freshnessValidatedDate: never | |||||
| This feature is currently provided as part of a preview program pursuant to our [pre-release policies](/docs/licenses/license-information/referenced-policies/new-relic-pre-release-policy). | ||||||
| </Callout> | ||||||
|
|
||||||
| Are you looking to gain deeper insights into your service architecture by leveraging data from your on-premise GitHub Enterprise account? The New Relic GitHub Enterprise integration imports repositories, teams, and user data directly into the New Relic platform using a secure collector service deployed within your private network. | ||||||
| Are you looking to gain deeper insights into your service architecture by leveraging data from your on-premise GitHub Enterprise account? The New Relic GitHub Enterprise integration imports repositories, and teams directly into the New Relic platform using a secure collector service deployed within your private network. | ||||||
|
|
||||||
| With the new selective data fetching feature, you can choose exactly which data types to import—whether it's teams, repositories and pull requests, or both. This integration aims to enhance the management and visibility of Teams, Catalogs and Scorecards within New Relic. For more information, refer to the Service Architecture Intelligence capability. | ||||||
|
|
||||||
| This integration streamlines the onboarding process for users and teams while simplifying role management. It also clarifies entity ownership mapping, reducing setup time and effort. Due to the restricted nature of GHE environments, integration is achieved via a local collector service deployed within your private network. This integration aims to enhance the management and visibility of [Catalogs](/docs/service-architecture-intelligence/catalogs/catalogs) and [Scorecards](/docs/service-architecture-intelligence/scorecards/getting-started) within New Relic. For more information, refer to the [Service Architecture Intelligence capability](/docs/service-architecture-intelligence/getting-started). | ||||||
|
|
||||||
| **Prerequisites** | ||||||
|
|
||||||
|
|
@@ -34,27 +35,132 @@ In your GHE instance, navigate to **Settings → Developer Settings → GitHub A | |||||
|
|
||||||
| ### Configure permissions | ||||||
|
|
||||||
| Set the specific permissions required for the app to perform real-time and initial data syncs. For detailed guidance on GitHub App permissions, refer to the [GitHub documentation on setting permissions for GitHub Apps](https://docs.github.com/en/apps/creating-github-apps/setting-up-a-github-app/setting-permissions-for-github-apps). | ||||||
|
|
||||||
| **Required Repository Permissions**: | ||||||
| - **Contents**: Read (to access repository files and content) | ||||||
| - **Metadata**: Read (to access basic repository information) | ||||||
| - **Issues**: Read (to access issue data) | ||||||
| - **Pull requests**: Read (to access pull request data) | ||||||
| - **Repository security advisories**: Read (to access security information) | ||||||
|
|
||||||
| **Required Organization Permissions**: | ||||||
| - **Members**: Read (to access organization member information) | ||||||
| - **Organization administration**: Read (to access organization settings) | ||||||
| - **Team discussions**: Read (to access team information) | ||||||
| When integrating a GitHub application, it's essential to configure app permissions accurately to ensure seamless data fetching during the initial sync and efficient listening to webhook events thereafter. App permissions define the scope of access that the application has to various repository and organizational resources on GitHub. By tailoring these permissions, you can enhance security, ensuring that the application only accesses the necessary data while minimizing exposure. Proper configuration facilitates smooth initial data synchronization and reliable event handling, optimizing the application's integration with GitHub's ecosystem. | ||||||
|
|
||||||
| For detailed guidance on GitHub App permissions, refer to the [GitHub documentation on setting permissions for GitHub Apps](https://docs.github.com/en/apps/creating-github-apps/setting-up-a-github-app/setting-permissions-for-github-apps). | ||||||
|
|
||||||
| #### Required repository permissions | ||||||
|
|
||||||
| Configure the following repository-level permissions exactly as shown to enable data synchronization: | ||||||
|
|
||||||
| - **Administration**: Read-only ✓ | ||||||
| - **Checks**: Read-only ✓ | ||||||
| - **Commit statuses**: Selected ✓ | ||||||
| - **Contents**: Selected ✓ | ||||||
| - **Custom properties**: Selected ✓ | ||||||
| - **Deployments**: Read-only ✓ | ||||||
| - **Metadata**: Read-only (mandatory) ✓ | ||||||
| - **Pull requests**: Selected ✓ | ||||||
| - **Webhooks**: Read-only ✓ | ||||||
|
|
||||||
| **Leave these permissions as "No access":** | ||||||
| - Actions | ||||||
| - Attestations | ||||||
| - Code scanning alerts | ||||||
| - Codespaces | ||||||
| - Codespaces lifecycle admin | ||||||
| - Codespaces metadata | ||||||
| - Codespaces secrets | ||||||
| - Dependabot alerts | ||||||
| - Dependabot secrets | ||||||
| - Discussions | ||||||
| - Environments | ||||||
| - Issues | ||||||
| - Merge queues | ||||||
| - Packages | ||||||
| - Pages | ||||||
| - Projects | ||||||
| - Repository security advisories | ||||||
| - Secret scanning alert dismissal requests | ||||||
| - Secret scanning alerts | ||||||
| - Secret scanning push protection bypass requests | ||||||
| - Secrets | ||||||
| - Single file | ||||||
| - Variables | ||||||
| - Workflows | ||||||
|
|
||||||
| #### Required organization permissions | ||||||
|
|
||||||
| Configure the following organization-level permissions exactly as shown: | ||||||
|
|
||||||
| - **Administration**: Read-only ✓ | ||||||
| - **Custom organization roles**: Selected ✓ | ||||||
| - **Custom properties**: Selected ✓ | ||||||
| - **Custom repository roles**: Selected ✓ | ||||||
| - **Events**: Selected ✓ | ||||||
| - **Members**: Selected ✓ | ||||||
| - **Webhooks**: Selected ✓ | ||||||
|
|
||||||
| **Leave these permissions as "No access":** | ||||||
| - Blocking users | ||||||
| - Organization announcement banners | ||||||
| - Organization codespaces | ||||||
| - Organization codespaces secrets | ||||||
| - Organization codespaces settings | ||||||
| - Organization dependabot secrets | ||||||
| - Organization hooks | ||||||
| - Organization packages | ||||||
| - Organization plan | ||||||
| - Organization projects | ||||||
| - Organization secrets | ||||||
| - Organization self hosted runners | ||||||
| - Plan | ||||||
| - Team discussions | ||||||
|
|
||||||
| #### Required account permissions | ||||||
|
|
||||||
| Enable account-level access for user identification: | ||||||
|
|
||||||
| **Required Account Permissions**: | ||||||
| - **Email addresses**: Read (to access user email information) | ||||||
|
|
||||||
| **Subscribe to Events**: Enable the following webhook events for real-time synchronization: | ||||||
| - Repository events: `repository`, `push`, `pull_request`, `issues` | ||||||
| - Organization events: `organization`, `team`, `membership` | ||||||
| - Security events: `repository_vulnerability_alert`, `security_advisory` | ||||||
| #### Webhook event subscriptions | ||||||
|
|
||||||
| Select the following webhook events exactly as shown for real-time synchronization and monitoring: | ||||||
|
|
||||||
| **✓ Select these events:** | ||||||
| - `commit_comment` - Comments on commits | ||||||
| - `create` - Branch or tag creation | ||||||
| - `custom_property` - Custom property changes for team assignments | ||||||
| - `delete` - Branch or tag deletion | ||||||
| - `deployment` - Deployment activities | ||||||
| - `deployment_review` - Deployment review processes | ||||||
| - `deployment_status` - Deployment status updates | ||||||
| - `installation_target` - GitHub App installation changes | ||||||
| - `member` - Member profile changes | ||||||
| - `membership` - Member additions and removals | ||||||
| - `organization` - Organization-level changes | ||||||
| - `pull_request` - Pull request activities | ||||||
| - `pull_request_review` - Pull request review activities | ||||||
| - `pull_request_review_comment` - Review comment activities | ||||||
| - `push` - Code pushes and commits | ||||||
| - `repository` - Repository creation, deletion, and modifications | ||||||
| - `team` - Team creation and modifications | ||||||
| - `team_add` - Team member additions | ||||||
|
|
||||||
| **Leave these events unselected:** | ||||||
| - `branch_protection_configuration` | ||||||
| - `check_run` | ||||||
| - `fork` | ||||||
| - `gollum` | ||||||
| - `issues` | ||||||
| - `label` | ||||||
| - `merge_queue_entry` | ||||||
| - `meta` | ||||||
| - `milestone` | ||||||
| - `public` | ||||||
| - `release` | ||||||
| - `repository_dispatch` | ||||||
| - `repository_ruleset` | ||||||
| - `security_and_analysis` | ||||||
| - `star` | ||||||
| - `status` | ||||||
| - `watch` | ||||||
| - `workflow_dispatch` | ||||||
| - `workflow_job` | ||||||
|
|
||||||
| <Callout variant="tip"> | ||||||
| **Security best practice**: Only enable the minimum permissions required for your integration needs. This reduces security exposure and follows the principle of least privilege access. | ||||||
| </Callout> | ||||||
|
|
||||||
| ### Set up webhooks | ||||||
|
|
||||||
|
|
@@ -67,23 +173,29 @@ Configure the Webhook URL and create a custom Event Secret for secure communicat | |||||
| **Example**: If your collector service is deployed at `collector.yourcompany.com`, the webhook URL would be: | ||||||
| `https://collector.yourcompany.com:8443/webhook` | ||||||
|
|
||||||
| - **Event Secret**: Generate a secure random string (32+ characters) for webhook authentication. Save this value as you'll need it for the `EVENT_SECRET` environment variable. | ||||||
| - **Event Secret**: Generate a secure random string (32+ characters) for webhook authentication. Save this value as you'll need it for the `GITHUB_APP_WEBHOOK_SECRET` environment variable. | ||||||
|
|
||||||
| ### Generate and convert keys | ||||||
|
|
||||||
| 1. Upon creation, the app will generate a unique App ID and a Private Key file (.pem format). Save these securely as they will be needed for the collector service configuration. | ||||||
|
||||||
| 1. Upon creation, the app will generate a unique App ID and a Private Key file (.pem format). Save these securely as they will be needed for the collector service configuration. | |
| 1. Upon creation, the app generates a unique App ID and a Private Key file (.pem format). Save these securely as you need them for the collector service configuration. |
Contributor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggested change
| 2. Click **First time sync** to start the initial data synchronization. | |
| 2. To start the initial data synchronization, click **First time sync**. |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.