From 6c17fb49ef03908856ad7e22d9db1a6668969299 Mon Sep 17 00:00:00 2001 From: Chong Cheung Date: Tue, 27 May 2014 14:12:49 +0800 Subject: [PATCH] Update mongo.rst 1. Use db.createUser() instead of db.addUser() to add users to MongoDB. Deprecated since version 2.6 2. NodeBB causes mongo error during setup procedure. Change the role from "userAdmin" to "readWrite". --- docs/configuring/databases/mongo.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/configuring/databases/mongo.rst b/docs/configuring/databases/mongo.rst index 64955a9133..a102db01d0 100644 --- a/docs/configuring/databases/mongo.rst +++ b/docs/configuring/databases/mongo.rst @@ -67,11 +67,11 @@ To add a user to access the `nodebb` database, type: .. code:: - > db.addUser( { user: "nodebb", + > db.createUser( { user: "nodebb", ... pwd: "", - ... roles: [ "userAdmin" ] } ) + ... roles: [ "readWrite" ] } ) -**Note:** The role ``userAdmin`` gives all permissions to the user for that specific database. +**Note:** The role ``readWrite`` provides read or write any collection within a specific database to user. Step 7: Configure MongoDB ------------------------- @@ -123,4 +123,4 @@ To start the app, run: Now visit ``yourdomainorip.com:4567`` and your NodeBB installation should be running. -NodeBB can also be started with helper programs, such as :doc:`supervisor or forever <../../running/index>`. You can also use ``nginx`` as a :doc:`reverse proxy <../../configuring/proxies>`). \ No newline at end of file +NodeBB can also be started with helper programs, such as :doc:`supervisor or forever <../../running/index>`. You can also use ``nginx`` as a :doc:`reverse proxy <../../configuring/proxies>`).