Support authorization headers for GitHub Mirroring
Problem to solve
Currently with repository mirroring, we support the use of a personal access token with basic authentication when communicating with GitHub. While they are not deprecating basic authentication support, they do include examples of using the personal access token with the Authorization
header in their recent release about the deprecation of password usage: https://developer.github.com/changes/2020-02-14-deprecating-password-auth/
In other examples, GitHub continues to use the personal access token with basic authentication, and there are currently no signs to deprecate this, but this issue serves to offer additional support in the form of Authorization
headers.
Proposal
We'll need to support a new authentication method
and potentially accept a new field in the push and pull mirroring configuration for a token, then we'll need to begin using the new authentication method in addition to basic authentication.