From 9e38a0cc29e4026c361f8891e9e3d2d1096c5c9f Mon Sep 17 00:00:00 2001
From: VED PRAKASH KASHYAP <ved.kashyap@samsung.com>
Date: Fri, 9 May 2025 22:42:23 +0530
Subject: [PATCH] docs: fix for role sync issues in case of custom OAuth2
 configuration (#30878)

---
 docs/docs/configuration/configuring-superset.mdx | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/docs/docs/configuration/configuring-superset.mdx b/docs/docs/configuration/configuring-superset.mdx
index 0fb208d4f8..1a453adfe3 100644
--- a/docs/docs/configuration/configuring-superset.mdx
+++ b/docs/docs/configuration/configuring-superset.mdx
@@ -302,6 +302,15 @@ AUTH_USER_REGISTRATION = True
 AUTH_USER_REGISTRATION_ROLE = "Public"
 ```
 
+In case you want to assign the `Admin` role on new user registration, it can be assigned as follows:
+```python
+AUTH_USER_REGISTRATION_ROLE = "Admin"
+```
+If you encounter the [issue](https://github.com/apache/superset/issues/13243) of not being able to list users from the Superset main page settings, although a newly registered user has an `Admin` role, please re-run `superset init` to sync the required permissions. Below is the command to re-run `superset init` using docker compose.
+```
+docker-compose exec superset superset init
+```
+
 Then, create a `CustomSsoSecurityManager` that extends `SupersetSecurityManager` and overrides
 `oauth_user_info`:
 
-- 
GitLab