]> git.immae.eu Git - github/fretlink/ansible-rabbitmq.git/commitdiff
Merge pull request #19 from gaetanfl/fix_vhost
authorLarry Smith Jr <mrlesmithjr@gmail.com>
Thu, 20 Dec 2018 05:53:16 +0000 (00:53 -0500)
committerGitHub <noreply@github.com>
Thu, 20 Dec 2018 05:53:16 +0000 (00:53 -0500)
add vhost for exchange and queue declaration

1  2 
tasks/rabbitmq_ha_config.yml

index e62fc83301cbcbf038cc0a4af85836da2de5db69,ffda6e9b76c0e60bc5651ef7383110619e954c1f..9ebe29774829a51c16f53c108e659ff25afdc4a7
    when: not rabbitmqadmin_check['stat']['exists']
  
  - name: rabbitmq_ha_config | creating queue(s)
-   command: rabbitmqadmin declare queue name={{ item['queue_name'] }} durable={{ item['durable']|lower }}
+   command: rabbitmqadmin declare queue name={{ item['queue_name'] }} durable={{ item['durable']|lower }} --vhost={{ item['vhost'] | default('/') }}
    run_once: true
    become: true
 +  when:
 +    - item['queue_name'] is defined
    with_items: "{{ rabbitmq_config }}"
  
  - name: rabbitmq_ha_config | setting up ha on queue(s)