Mongo assigning user permsions issue on docker
okay, I make it work like this

#!/bin/bash
set -e;

mongo -u mongo -p asdfasdf --authenticationDatabase admin &lt;&lt;-EOJS
    use notifications;
    db.createUser({
      user: "mongouser",
      pwd: "asdfasdf",
      roles: [  {role: "readWrite", db: "notifications" }  ]
    });
    use translations;
    db.createUser({
      user: "mongouser",
      pwd: "asdfasdf",
      roles: [  {role: "readWrite", db: "translations" }  ]
    });

    exit;
    EOJS


but why I need to create separate users, why I can't assign the same usr to multiple databases?