diff options
-rw-r--r-- | tasks/rabbitmq_ha_config.yml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tasks/rabbitmq_ha_config.yml b/tasks/rabbitmq_ha_config.yml index bf74957..ffda6e9 100644 --- a/tasks/rabbitmq_ha_config.yml +++ b/tasks/rabbitmq_ha_config.yml | |||
@@ -21,7 +21,7 @@ | |||
21 | when: not rabbitmqadmin_check['stat']['exists'] | 21 | when: not rabbitmqadmin_check['stat']['exists'] |
22 | 22 | ||
23 | - name: rabbitmq_ha_config | creating queue(s) | 23 | - name: rabbitmq_ha_config | creating queue(s) |
24 | command: rabbitmqadmin declare queue name={{ item['queue_name'] }} durable={{ item['durable']|lower }} | 24 | command: rabbitmqadmin declare queue name={{ item['queue_name'] }} durable={{ item['durable']|lower }} --vhost={{ item['vhost'] | default('/') }} |
25 | run_once: true | 25 | run_once: true |
26 | become: true | 26 | become: true |
27 | with_items: "{{ rabbitmq_config }}" | 27 | with_items: "{{ rabbitmq_config }}" |
@@ -37,14 +37,14 @@ | |||
37 | with_items: "{{ rabbitmq_config }}" | 37 | with_items: "{{ rabbitmq_config }}" |
38 | 38 | ||
39 | - name: rabbitmq_ha_config | creating exchange(s) | 39 | - name: rabbitmq_ha_config | creating exchange(s) |
40 | command: rabbitmqadmin declare exchange name={{ item['exchange_name'] }} type={{ item['type'] }} | 40 | command: rabbitmqadmin declare exchange name={{ item['exchange_name'] }} type={{ item['type'] }} --vhost={{ item['vhost'] | default('/') }} |
41 | run_once: true | 41 | run_once: true |
42 | become: true | 42 | become: true |
43 | with_items: "{{ rabbitmq_config }}" | 43 | with_items: "{{ rabbitmq_config }}" |
44 | when: item['exchange_name'] is defined | 44 | when: item['exchange_name'] is defined |
45 | 45 | ||
46 | - name: rabbitmq_ha_config | creating binding(s) | 46 | - name: rabbitmq_ha_config | creating binding(s) |
47 | command: rabbitmqadmin declare binding source={{ item['exchange_name'] }} destination_type="queue" destination={{ item['queue_name'] }} routing_key={{ item['routing_key'] }} | 47 | command: rabbitmqadmin declare binding source={{ item['exchange_name'] }} destination_type="queue" destination={{ item['queue_name'] }} routing_key={{ item['routing_key'] }} --vhost={{ item['vhost'] | default('/') }} |
48 | run_once: true | 48 | run_once: true |
49 | become: true | 49 | become: true |
50 | with_items: "{{ rabbitmq_config }}" | 50 | with_items: "{{ rabbitmq_config }}" |