Suggestions
:seedling:
Gitea
Gitea is a major self-hosted equivalent to sites like Gitlab and Github. It has a full API and OAuth2 authentication, so integrating it on the back-end should be doable and can likely reuse most of the code for the current Github integration. The major difference is the URL would need to be entered by the user rather than hard-coded into the integration.