-
Notifications
You must be signed in to change notification settings - Fork 143
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
failed to initialize provider, error: failed creating Gitea client: 403 Forbidden #580
Comments
What is the exact error you're getting? I just upgrade to Gitea 1.20 and it's working fine with an existing token. |
there is no other error. btw the apikey had repo scope only before the Gitea upgrade and was working fine. btw: I also updated flux from v2 rc to v2.0.1 today. maybe there has something changed too? |
You still haven't pasted the error you're seeing into this issue. The only thing you did was post a link to the source code where that error supposedly originates. Pasting the actual error you're seeing may help understanding what's causing it.
I tried 2.0.1 and didn't run into any issues. |
sorry, the error is the issue title |
Are you using a token with full rights or a repo scoped? Did you created the token before updating Gitea to v1.20? |
I created the Token on Gitea 1.18 so there was no way to choose its scope. After the upgrade to 1.20 it shows this scope:
|
so it seems to be an issue with the scopes, as the same token works fine for fetching the repo from flux. maybe some new scope is needed to initialize the Gitea client. do you know which calls it does ? will also check the Gitea logs to hopefully find the failed requests. |
What scope does the token you use (the one that doesn't work) have? |
@viceice Please supply as much information as possible on your issue and environment. Otherwise we will have to ask for each and every bit of information and won't be able to make any reasonable progress getting to the bottom of your problem. |
ok, will extend the issue description tomorrow |
Updated body. It seems the |
That is indeed interesting. We should definitely document the necessary minimum scopes. Thanks for digging into this. I just verified that the following scopes are necessary to make the provider work:
|
yes, I've added |
closes #580 Signed-off-by: Max Jonas Werner <mail@makk.es>
it seems misc is no longer necessary since v1.20.2 |
closes #580 Signed-off-by: Max Jonas Werner <mail@makk.es>
closes #580 Signed-off-by: Max Jonas Werner <mail@makk.es>
closes #580 Signed-off-by: Max Jonas Werner <mail@makk.es>
closes #580 Signed-off-by: Max Jonas Werner <mail@makk.es>
closes #580 Signed-off-by: Max Jonas Werner <mail@makk.es>
closes #580 Signed-off-by: Max Jonas Werner <mail@makk.es>
closes #580 Signed-off-by: Max Jonas Werner <mail@makk.es>
Since Gitea upgrade from v1.19 to v1.20 i get this error. 😕
notification-controller/internal/notifier/gitea.go
Line 69 in b80c2c4
I know they changed the api key scopes1, but the key still has repo write scope. My current key was created on v1.19.x with repo scope.
It had these scopes:
It's now converted to these scopes:
Gitea log message:
Please let me know how to debug this futher. Are there any option to pass additional debug messages?
Footnotes
https://blog.gitea.com/release-of-1.20.0/#%EF%B8%8F-refactored-scoped-tokens-mechanism-24767 ↩
The text was updated successfully, but these errors were encountered: