Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //after creating of the user, MongoDB process should be started with authentication support
- // add following lines to your mongodb config file:
- // security:
- // authorization: "enabled"
- // Note: config file has YAML, it is pretty sensitive to tabs vs spaces - so in some cases MongoDB process cannot be started because some characters are wrong (make sure there are spaces instead of tabs)
- var userName = "msa";
- var passWord = "Sitecore12345";
- var analyticsDB = "basicsitecore_analytics"
- var trackingContactDB = "basicsitecore_tracking_contact"
- var trackingLiveDB = "basicsitecore_tracking_live"
- var trackingHistoryDB = "basicsitecore_tracking_history"
- use basicsitecore_analytics
- db.createUser(
- {
- user: userName,
- pwd: passWord,
- roles: [ { role: "readWrite", db: analyticsDB } ]
- }
- );
- use basicsitecore_tracking_contact
- db.createUser(
- {
- user: userName,
- pwd: passWord,
- roles: [ { role: "readWrite", db: trackingContactDB} ]
- }
- );
- use basicsitecore_tracking_live
- db.createUser(
- {
- user: userName,
- pwd: passWord,
- roles: [ { role: "readWrite", db: trackingLiveDB} ]
- }
- );
- use basicsitecore_tracking_history
- db.createUser(
- {
- user: userName,
- pwd: passWord,
- roles: [ { role: "readWrite", db: trackingHistoryDB } ]
- }
- );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement