在 MongoDB Atlas 中添加 userAdmin
Add userAdmin in MongoDB Atlas
如何在 Atlas 中添加具有 userAdmin 角色的用户?
Cluster Security "Add New User" UI https://cloud.mongodb.com/v2/.....#clusters/security/users 仅显示有限的一组内置角色,没有任何手动输入角色名称的选项:
所以我有点卡在这里 - UI 中没有选项,并且现有角色中没有一个允许在 shell 中添加用户。
列表中的 None 个角色拥有 userAdmin
权限。
在创建集群页面上分配给用户的最多 "powerful" atlasAdmin 仅涵盖:
- readWriteAnyDatabase
- readAnyDatabase
- 启用分片
- dbAdminAnyDatabase
- 集群监控
并且没有足够的权限在 shell.
中执行 db.createUser()
命令
您不能授予此角色。 仅 在 Atlas 中创建新 MongoDB 用户的方法是通过 UI 或 API。有关详细信息,请参阅 Add MongoDB Users 并注意此页面声明:
Atlas rolls back any user modifications not made through the UI or API. You must use the Atlas UI or API to add, modify, or delete MongoDB users on Atlas clusters.
有关如何通过 API 创建 MongoDB 用户的详细信息,请参阅 Create a Database User。
如何在 Atlas 中添加具有 userAdmin 角色的用户?
Cluster Security "Add New User" UI https://cloud.mongodb.com/v2/.....#clusters/security/users 仅显示有限的一组内置角色,没有任何手动输入角色名称的选项:
所以我有点卡在这里 - UI 中没有选项,并且现有角色中没有一个允许在 shell 中添加用户。
列表中的None 个角色拥有 userAdmin
权限。
在创建集群页面上分配给用户的最多 "powerful" atlasAdmin 仅涵盖:
- readWriteAnyDatabase
- readAnyDatabase
- 启用分片
- dbAdminAnyDatabase
- 集群监控
并且没有足够的权限在 shell.
中执行db.createUser()
命令
您不能授予此角色。 仅 在 Atlas 中创建新 MongoDB 用户的方法是通过 UI 或 API。有关详细信息,请参阅 Add MongoDB Users 并注意此页面声明:
Atlas rolls back any user modifications not made through the UI or API. You must use the Atlas UI or API to add, modify, or delete MongoDB users on Atlas clusters.
有关如何通过 API 创建 MongoDB 用户的详细信息,请参阅 Create a Database User。