ansible-collections / community.rabbitmq

Manage RabbitMQ with Ansible
http://galaxy.ansible.com/community/rabbitmq
Other
30 stars 46 forks source link

Add an option to allow rabbitmq_vhost to use API for managing users #171

Open Thorsieger opened 4 months ago

Thorsieger commented 4 months ago
SUMMARY

Feature request similar to https://github.com/ansible-collections/community.rabbitmq/issues/76 : rabbitmq_vhost uses rabbitmqctl for managing users. The idea is to add a choice for allowing to use API as well.

ISSUE TYPE

Managing exchanges, queues, bindings and user can be perform using rabbitmq API. It will be nice to have the same for vhosts.

COMPONENT NAME

https://github.com/ansible-collections/community.rabbitmq/blob/main/plugins/modules/rabbitmq_vhost.py

ADDITIONAL INFORMATION

Using the documentation, the configuration could looks like this :

- name: Ensure that the vhost /test exists.
  community.rabbitmq.rabbitmq_vhost:
    name: /test
    state: present
    provider: api
    login_user: user
    login_password: secret
    login_host: remote.example.org