Reputation: 145
MongoDB's documentation is clear about roles needed for other operations. I may be overlooking something, but I couldn't find a clear description of how to create a new database.
I am trying to do this from a remote Node.js server. One that should be able to create databases and create users.
Upvotes: 1
Views: 37
Reputation: 5252
According to the MongoDB documentation you need the dbAdmin
and userAdmin
roles, but the dbOwner
role also can fit your needs (depends on the details of your task). Also you can create a custom role.
Upvotes: 1