Search code examples
rabbitmq

How do I create or add a user to rabbitmq?


This seems like a question that should be easily be googleable. It is not though. Can anybody help?

How do I create a new user for rabbitmq?


Solution

  • You can use the rabbitmqctl tool - look for subtitle User management. The command to create a user is:

    $ rabbitmqctl add_user myUser myPass
    

    To make user an administrator run:

    $ rabbitmqctl set_user_tags myUser administrator
    

    Also if you use rabbitmq web UI - the management plugin you can do it quite easily, it's pretty intuitive.

    If you want to do it programmatically you can also use rabbitmq rest API, also explained in (on?) the link for management plugin.