Forum Discussion
How to add custom GitHub Apps in Azure DevOps?
Hello!
We have quite a large mono repo and more than 30-40 teams participate and we have more than 150+ pipelines that get triggered for team-specific commits. We use the default Azure pipelines GitHub App to connect the Azure DevOps with GitHub repos. Since it's a large request considerably other repos also utilize this app in our organization.
We started getting the GitHub rate limit issue as the Azure Pipelines GitHub app gets about 15000 requests per hour at least twice or thrice a day. So, the GitHub support suggested creating a custom GitHub app and using some of the Azure pipelines to use the new app.
We need some help on how to add the custom-created GitHub app in Azure DevOps. We can only see OAuth App integration for GitHub, but how to add GitHub Apps integration? If we use the OAuth App integration we get repos not available when the new custom app actually has access to the repos.
Thanks,
Sundar.
1 Reply
Direct integration with custom GitHub Apps is not supported yet but you may consider below workarounds:
- Use a Personal Access Token (PAT) or GitHub OAuth Token
- Create a GitHub PAT with appropriate repo and workflow scopes.
- In Azure DevOps, go to Project Settings > Service Connections.
- Create a new GitHub service connection using the PAT.
- Use this connection in your pipelines to access the repos tied to your custom GitHub App.
This bypasses the GitHub App model entirely and gives you more control over rate limits by distributing traffic across multiple tokens.
- Split Pipelines Across Multiple GitHub Apps
- Create multiple GitHub Apps and install them on subsets of your repos.
- Use GitHub Actions for some pipelines and Azure Pipelines for others, depending on the app used.
- Unfortunately, Azure DevOps doesn’t let you register a custom GitHub App directly, so this would require using webhooks or external triggers to bridge the gap.