If I have two Meteor Apps connecting to a single MongoDB instance, can I have the Accounts package create two separate User collections? One for internal company users, and one for public users?
Wouldn’t this be better handled by Roles?
Possibly. I guess I’m not sure wether it’s best to keep public accounts in the same collection as internal company accounts.
@purplecones did you found solution to your problem? I am working at admin panel for my app and I don’t want to mix admin accounts with users accounts. So far I created second collection named admins
using below code.
Accounts.users = new Mongo.Collection('admins', {
_preventAutopublish: true
});
Meteor.users = Accounts.users;
I can login etc. using admins
collection, but I can’t use users
collection anymore, this is normal because I’ve overwritted Meteor.users
. Something like
export const Users = new Mongo.Collection('users');
Throws error about users
collection duplicate. Is there any solution without digging up in accounts
packages?
Thanks guys