Details
-
Improvement
-
Status: Closed
-
Major - P3
-
Resolution: Fixed
-
None
-
*Location*: http://docs.mongodb.org/manual/reference/method/db.createUser/#db.createUser
*User-Agent*: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1985.125 Safari/537.36
*Referrer*: http://docs.mongodb.org/manual/reference/method/js-user-management/
*Screen Resolution*: 1024 x 1280
*repo*: docs
*source*: reference/method/db.createUser
*Location*: http://docs.mongodb.org/manual/reference/method/db.createUser/#db.createUser *User-Agent*: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1985.125 Safari/537.36 *Referrer*: http://docs.mongodb.org/manual/reference/method/js-user-management/ *Screen Resolution*: 1024 x 1280 *repo*: docs *source*: reference/method/db.createUser
-
4
-
true
Description
In the roles section of what fields are required. It doesn't mention that the roles are optional. On the db.createRole page it says "You must specify the privileges field. Use an empty array to specify no privileges." in the privileges field, the roles field should say something similar.
I had to create a user with no roles then grant them later on in the script but I had to initially guess that mongodb wouldnt error when I tried to create a user without roles.