How to create admin users?


This sound very easy but i dont know how to approach this. i create a blog where im able to create “regular” user registration. they can add blog post and comment. and then i want to create admin. who cant delete/edit the regular user’s post… i used. meteor add accounts-password package


Meteor doesn’t have a built in roles/permissions system, that’s up to you.

You could just do something like Meteor.users.update(userId, {$set:{admin:true}})
or Meteor.users.update(userId, {$set:{role:'admin'}})
or Meteor.users.update(userId, {$set:{permissions:['editUsers','editPosts']}})
And then you check those fields.

1 Like

thank you sir. so to make a admin user. i need to manually do it in the back end.



@copleykj thank you! its easy to use! btw is there a way to configure the meteor accout ui:password ?


This may be what you are looking for…

1 Like

@copleykj thank you again!

1 Like