Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Gitea OAuth #33

Closed
KNOXDEV opened this issue Jun 4, 2019 · 4 comments
Closed

Add support for Gitea OAuth #33

KNOXDEV opened this issue Jun 4, 2019 · 4 comments
Labels
duplicate This issue or pull request already exists

Comments

@KNOXDEV
Copy link

KNOXDEV commented Jun 4, 2019

As long as this is a project for self-hosted open directories, we might as well add support for self-hosted github-like services like Gitea: https://docs.gitea.io/en-us/oauth2-provider/

Shouldn't require anything complex on top of what the Github OAuth already does other than the ability to configure the Gitea instance hostname in config.json, which is arguably what the Github configuration should already have since self-hosted Github Enterprise is a thing.

@KNOXDEV
Copy link
Author

KNOXDEV commented Jun 4, 2019

Just briefly glancing at the project structure, it seems like OAuth is provided by your external library, https://github.com/nektro/go.oauth2

There's nothing wrong with this, but the project doesn't seem to have support for configuring providers with a custom hostname, which means adding this kind of support isn't 100% drop in addable without a few structure changes. In other words, it might be involved.

@nektro
Copy link
Owner

nektro commented Jun 4, 2019

Since GitTea is a self-hosted service it cannot be added to nektro/go.oauth2 as a pre-loaded identity provider, but I also just created #34 which should solve this issue and support more self-hosted services in the future.

@nektro
Copy link
Owner

nektro commented Jun 4, 2019

A section will be needed to be added to config.json that allows users to load their own Providers at outlined in https://github.com/nektro/go.oauth2/blob/master/provider.go

@nektro nektro added the duplicate This issue or pull request already exists label Jun 4, 2019
@KNOXDEV
Copy link
Author

KNOXDEV commented Jun 4, 2019

Alright, so long as there's a solution.

@KNOXDEV KNOXDEV closed this as completed Jun 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants