-
Notifications
You must be signed in to change notification settings - Fork 327
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
Configuration for Gitea #203
Comments
Looks like support for Gitea is not working until Gitea supports oauth user info (go-gitea/gitea#8534). Maybe should update couch's readme to not claim support for Gitea and reference Gitea's GitHub issue. |
Until Gitea supports user info, maybe consider adding Gitea as a separate provider without user info similar to IndieAuth, Google and ADFS? |
Thanks for the recon.
Did you try with 'github' provider?
…On Sun, Feb 2, 2020, 12:11 PM Jeffrey Layanto ***@***.***> wrote:
Until Gitea supports user info, maybe consider adding Gitea as a separate
provider without user info similar to IndieAuth, Google and ADFS?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#203?email_source=notifications&email_token=AAJUV2757XRSHDWU2CQFRDLRA4SGBA5CNFSM4KOV757KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEKR7XMY#issuecomment-581172147>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJUV22NXRZUH6KPOW5PVM3RA4SGBANCNFSM4KOV757A>
.
|
According to the Gitea docs, the URL to return the current user is https://try.gitea.io/api/swagger#/user/userGetCurrent If their response from that URL isn't compatible with the current set of things that Vouch understands, it would be relatively simple to create a PR for Vouch to read that format. |
It looks like Gitea made their |
I will try with GitHub provider later today. But I saw this comment from one Gitea maintainer (I think) that suggested it won't work - go-gitea/gitea#8962 (comment) |
Ignore that, they're talking about the internal implementation of their new userinfo endpoint. I just tried it with the following config and it worked: oauth:
provider: github
client_id: XXXXX
client_secret: XXXXX
callback_url: http://vouch.example/auth
auth_url: https://gitea.example/login/oauth/authorize
token_url: https://gitea.example/login/oauth/access_token
user_info_url: https://gitea.example/api/v1/user?token= |
Awesome!
I'll adjust the README to point here next time I'm updating VP.
…On Sun, Feb 2, 2020, 1:19 PM Aaron Parecki ***@***.***> wrote:
Ignore that, they're talking about the internal implementation of their
new userinfo endpoint.
I just tried it with the following config and it worked:
oauth:
provider: github
client_id: XXXXX
client_secret: XXXXX
callback_url: http://vouch.example/auth
auth_url: https://gitea.example/login/oauth/authorize
token_url: https://gitea.example/login/oauth/access_token
user_info_url: https://gitea.example/api/v1/user?token=
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#203?email_source=notifications&email_token=AAJUV22UJBDS2GB55HDOAYDRA42GNA5CNFSM4KOV757KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEKSBIPI#issuecomment-581178429>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJUV2YGOIIRSR7F3LCAWSLRA42GNANCNFSM4KOV757A>
.
|
Tried this and it worked - meaning I can get to my protected app. But how do I check if the user info is retrieved correctly? I checked the header and couldn't find anything relating to the logged in user. |
Confirmed working. I can access Gitea username via $auth_resp_x_vouch_user. Thanks @aaronpk. |
Vouch stated support for Gitea (#170) but I can't get it to work. Following Gitea oauth docs (https://docs.gitea.io/en-us/oauth2-provider/), I have configured vouch provider as follows:
I don't think Gitea oauth provides user information. If I left out user_info_url from vouch config.yml, I get panic error.
Appreciate help from anyone who managed to get integration with Gitea working. I will then raise PR with example to help the next person.
The text was updated successfully, but these errors were encountered: