Concourse CI and Gitea OAuth

Hello,

I am trying to setup concourse ci to authenticate via oauth2 and gitea.

I am working off of:
https://docs.gitea.io/en-us/oauth2-provider/ and
https://concourse-ci.org/generic-oauth.html
I am close, but now getting from concourse:

Failed to authenticate: OAuth connector: failed to get token: oauth2: cannot fetch token: 400 Bad Request Response: {“error”:“unauthorized_client”,“error_description”:“client is not authorized”}

Is there any tools you like to use to troubleshoot?

Browser dev tools are the most important part- turn on persistence in the network tab, and you can trace what happens as your browser shuttles back and forth.

For this, double check your CONCOURSE_OAUTH_CLIENT_SECRET, and make sure gitea knows about it.

I double checked the client secret and that looks ok.

Started up devoloper tools. Now got this information:

Internal Server Error

Failed to return user’s identity.

Headers:

  1. Request Method:
    GET
  2. Status Code:
    500 Internal Server Error
  3. Remote Address:
    10.10.10.10:8081
  4. Referrer Policy:
    no-referrer-when-downgrade

I wonder if I have this part wrong:
CONCOURSE_OAUTH_USERINFO_URL=http://10.10.10.20:3000/api/v1/users/

Its not real clear to me what needs to go there.