Auth: Enforce role sync except if skip org role sync is enabled (#70766)

* enforce role sync except if skip org role sync is enabled

* move errors to errors file and set codes

* fix docs and defaults

* remove legacy parameter

* support fall through token-api in generic oauth

* fix error handling for generic_oauth

* Update pkg/login/social/generic_oauth.go

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

* Update pkg/login/social/gitlab_oauth_test.go

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

* Update pkg/login/social/gitlab_oauth_test.go

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

---------

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
This commit is contained in:
Jo
2023-07-17 15:58:16 +02:00
committed by GitHub
co-authored by Gabriel MABILLE
parent 5ca382c88a
commit 0ffd359801
14 changed files with 365 additions and 334 deletions
+1 -1
View File
@@ -439,7 +439,7 @@
# Set this value to automatically add new users to the provided organization (if auto_assign_org above is set to true)
;auto_assign_org_id = 1
# Default role new users will be automatically assigned (if auto_assign_org above is set to true)
# Default role new users will be automatically assigned
;auto_assign_org_role = Viewer
# Require email validation before sign up completes