Connect GitHub
An integration connects CloudWatch Omni to a tool your team already uses. When you connect
GitHub, you give Omni read-only access to the repositories that you choose. Omni reads
your code to show what each service does on the application map. Omni also writes
repository activity, such as pushes, pull requests, deployments, and workflow runs, as
change events to your account's default CloudWatch Dataset.
You manage the integration in Settings, on the Integrations page. A connection applies to your whole space. For information about the application map, see Monitor applications with the application map.
GitHub is available for spaces in these AWS Regions: US East (N. Virginia), US West (Oregon), and Europe (Ireland).
The following table describes the connection types. You can add one connection of each type.
| Connection type | Use it for | What you enter |
|---|---|---|
| GitHub.com | Repositories on github.com. No organization is
needed. |
None |
| GitHub Enterprise Cloud | An organization in your enterprise on github.com. |
The organization name |
| GitHub Enterprise Cloud with data residency | An organization on your
host. |
The organization name and the host URL, for example
https:// |
| GitHub Enterprise Server | An organization on your self-hosted server. The server must be reachable from the internet. | The organization name and the server URL, for example
https://github.example.com |
Before you connect, check the following:
-
You can create integrations in the space and write to the space's dataset (
cloudwatch:PutRecords). Without the dataset permission, Omni can't start the connection. -
For a GitHub Enterprise connection, you must be an owner of the organization.
-
For data residency and GitHub Enterprise Server, you must be signed in to the host and its single sign-on.
-
The console must be in the Region of your space.
Connect GitHub.com or GitHub Enterprise Cloud
To connect GitHub.com or GitHub Enterprise Cloud
-
In Settings, choose Integrations.
-
On the GitHub card, choose Add connection.
-
For Connection type, select GitHub.com or GitHub Enterprise Cloud.
-
For GitHub Enterprise Cloud, enter the Organization name.
-
Choose Continue to GitHub.
-
On GitHub, install the Amazon CloudWatch app.
-
Choose the repositories that Omni can read.
-
Approve the request.
Back in Omni, the connection shows Connected. If an organization owner must approve the app first, ask them to approve it, and then connect again.
Connect GitHub Enterprise Cloud with data residency or GitHub Enterprise Server
For these types, Omni creates a GitHub App in your organization, so you go to your host twice: first to create the app, and then to install it.
To connect data residency or GitHub Enterprise Server
-
In Settings, choose Integrations.
-
On the GitHub card, choose Add connection.
-
For Connection type, select GitHub Enterprise Cloud with data residency or GitHub Enterprise Server.
-
For Organization name, enter the organization name. For the host URL, enter only the host, with no path, on the default HTTPS port.
-
Choose Continue to GitHub.
-
On your host, create the GitHub App. Don't rename it.
-
Install the app.
-
Choose the repositories that Omni can read.
-
Approve the request.
Back in Omni, the connection shows Connected. Setup expires after 1 hour. If it expires or fails, choose Start over, or choose Remove to delete the connection.
What Omni can access in GitHub
You give the app read-only access to the repositories you choose: their contents and metadata, pull requests, issues, Actions, checks, deployments, commit statuses, and administration settings, and the organization's administration settings. Omni can't change your repositories or your organization. To change which repositories Omni can read, change the app's repository access in GitHub.
Disconnect an integration
On the connection in Settings, on the Integrations page, choose Disable. Omni stops reading the connection's repositories. Disconnecting doesn't remove the app from GitHub. To remove it completely, also uninstall the Amazon CloudWatch app in your GitHub account or organization settings. For data residency and GitHub Enterprise Server, delete the GitHub App that Omni created from the organization's settings on your host.
Who can manage integrations
Integrations apply to the whole space. One person connects, and the connection
works for everyone in the space. A member's grants decide whether they can connect,
change, or disconnect an integration: the integration create, update, and delete
actions. Connecting GitHub also needs cloudwatch:PutRecords on
the space's dataset. See Custom grant actions.