| I'm noting that Google solves this issue by providing "Projects" which are limited to "No Organization" or a single G-Suite organization. Github could solve this on their side by providing OAuth API client credentials which only work for a specific organization. One simple way to implement this feature is to offer a list of "whitelisted domains" as a config option, perhaps just a comma separated list. After Github authentication is successful, check the user's email address against the domain whitelist. That would require that user's have provided their email to Github and for Github to provide the email back to Jenkins. |