DEBOPS.RABBITMQ_MANAGEMENT(5)

NAME
debops.rabbitmq_management - Configure RabbitMQ Management Console

SYNOPSIS

debops service/rabbitmq_management [--limit group,host,...] [--diff] [--check] [--tags tag1,tag2,...] [--skip-tags tag1,tag2,...] [<ansible-playbook options>] ...

DESCRIPTION

RabbitMQ <https://www.rabbitmq.com/> is an Open Source message broker which supports AMQP <https://en.wikipedia.org/wiki/Advanced_Message_Queuing_Protocol>, STOMP <https://en.wikipedia.org/wiki/Streaming_Text_Oriented_Messaging_Protocol> and MQTT <https://en.wikipedia.org/wiki/MQTT> protocols.

This ansible role can be used to enable and configure the RabbitMQ Management Console <https://www.rabbitmq.com/management.html>. The role can configure the plugin in a locally installed RabbitMQ service, or configure a reverse proxy to a remote instance of RabbitMQ.

See the debops.rabbitmq_server Ansible role for general RabbitMQ service deployment and configuration.

GETTING STARTED

  Default configuration

The role will detect if an existing installation of RabbitMQ done by the debops.rabbitmq_server role is present on a host. If it's found, the Management Console will be configured locally. Otherwise, no RabbitMQ configuration will take place, but role will still install the nginx server on a host and configure a reverse proxy instance. In that case, you might want to modify the rabbitmq_management__app_host, rabbitmq_management__app_port and rabbitmq_management__app_protocol parameters to point to a remote RabbitMQ Management Console instance.

  Example inventory

To configure RabbitMQ Management Console on a host, it should be added to the [debops_service_rabbitmq_management] Ansible inventory group:

[debops_service_rabbitmq_management]
hostname

  Example playbook

If you are using this role without DebOps, here's an example Ansible playbook that uses the debops.rabbitmq_management role:

---
- name: Configure RabbitMQ Management Console
  collections: [ 'debops.debops', 'debops.roles01',
                 'debops.roles02', 'debops.roles03' ]
  hosts: [ 'debops_service_rabbitmq_management' ]
  become: True
  environment: '{{ inventory__environment | d({})
                   | combine(inventory__group_environment | d({}))
                   | combine(inventory__host_environment  | d({})) }}'
  pre_tasks:
    - name: Prepare rabbitmq_server environment
      import_role:
        name: 'rabbitmq_server'
        tasks_from: 'main_env'
      tags: [ 'role::rabbitmq_server', 'role::secret', 'role::rabbitmq_server:config' ]
  roles:
    - role: keyring
      tags: [ 'role::keyring', 'skip::keyring', 'role::nginx' ]
      keyring__dependent_apt_keys:
        - '{{ nginx__keyring__dependent_apt_keys }}'
    - role: secret
      tags: [ 'role::secret', 'role::rabbitmq_server', 'role::rabbitmq_server:config' ]
      secret__directories:
        - '{{ rabbitmq_server__secret__directories }}'
    - role: etc_services
      tags: [ 'role::etc_services', 'skip::etc_services' ]
      etc_services__dependent_list:
        - '{{ rabbitmq_management__etc_services__dependent_list }}'
    - role: apt_preferences
      tags: [ 'role::apt_preferences', 'skip::apt_preferences' ]
      apt_preferences__dependent_list:
        - '{{ nginx__apt_preferences__dependent_list }}'
    - role: ferm
      tags: [ 'role::ferm', 'skip::ferm' ]
      ferm__dependent_rules:
        - '{{ nginx__ferm__dependent_rules }}'
    - role: python
      tags: [ 'role::python', 'skip::python' ]
      python__dependent_packages3:
        - '{{ nginx__python__dependent_packages3 }}'
      python__dependent_packages2:
        - '{{ nginx__python__dependent_packages2 }}'
    - role: nginx
      tags: [ 'role::nginx', 'skip::nginx' ]
      nginx__dependent_servers:
        - '{{ rabbitmq_management__nginx__dependent_servers }}'
      nginx__dependent_upstreams:
        - '{{ rabbitmq_management__nginx__dependent_upstreams }}'
    - role: rabbitmq_server
      tags: [ 'role::rabbitmq_server', 'skip::rabbitmq_server' ]
      rabbitmq_server__dependent_role: 'rabbitmq_management'
      rabbitmq_server__dependent_state: '{{ rabbitmq_management__deploy_state }}'
      rabbitmq_server__dependent_config:
        - '{{ rabbitmq_management__rabbitmq_server__dependent_config }}'
    - role: rabbitmq_management
      tags: [ 'role::rabbitmq_management', 'skip::rabbitmq_management' ]

AUTHOR
Maciej Delmanowski

COPYRIGHT
2014-2022, Maciej Delmanowski, Nick Janetakis, Robin Schneider and others