Run notify setup when setup_host differs
There's a usecase, where all datasets might be the same, except setup_hosts. For example, when we use isolated rabbitmq cluster for RPC but shared one for notifications. And we have same set of users and vhosts there. In current state setup won't be performed, since vhosts and users are the same. Change-Id: Ib5c44327d5f1edc25bace79fdd057adabb0b4c14
This commit is contained in:
parent
567aa74319
commit
d38c743552
|
@ -68,7 +68,8 @@
|
||||||
state: "present"
|
state: "present"
|
||||||
when:
|
when:
|
||||||
- (_oslomsg_rpc_vhost is undefined) or
|
- (_oslomsg_rpc_vhost is undefined) or
|
||||||
(_oslomsg_notify_vhost != _oslomsg_rpc_vhost)
|
(_oslomsg_notify_vhost != _oslomsg_rpc_vhost) or
|
||||||
|
(_oslomsg_notify_setup_host != _oslomsg_rpc_setup_host)
|
||||||
|
|
||||||
- name: Apply Notify RabbitMQ vhost policies
|
- name: Apply Notify RabbitMQ vhost policies
|
||||||
community.rabbitmq.rabbitmq_policy:
|
community.rabbitmq.rabbitmq_policy:
|
||||||
|
@ -80,7 +81,8 @@
|
||||||
loop: "{{ _oslomsg_notify_policies | default([]) + oslomsg_notify_policies }}"
|
loop: "{{ _oslomsg_notify_policies | default([]) + oslomsg_notify_policies }}"
|
||||||
when:
|
when:
|
||||||
- (_oslomsg_rpc_vhost is undefined) or
|
- (_oslomsg_rpc_vhost is undefined) or
|
||||||
(_oslomsg_notify_vhost != _oslomsg_rpc_vhost)
|
(_oslomsg_notify_vhost != _oslomsg_rpc_vhost) or
|
||||||
|
(_oslomsg_notify_setup_host != _oslomsg_rpc_setup_host)
|
||||||
|
|
||||||
- name: Add Notify RabbitMQ user
|
- name: Add Notify RabbitMQ user
|
||||||
community.rabbitmq.rabbitmq_user:
|
community.rabbitmq.rabbitmq_user:
|
||||||
|
@ -95,7 +97,8 @@
|
||||||
no_log: true
|
no_log: true
|
||||||
when:
|
when:
|
||||||
- (_oslomsg_rpc_userid is undefined) or
|
- (_oslomsg_rpc_userid is undefined) or
|
||||||
(_oslomsg_notify_userid != _oslomsg_rpc_userid)
|
(_oslomsg_notify_userid != _oslomsg_rpc_userid) or
|
||||||
|
(_oslomsg_notify_setup_host != _oslomsg_rpc_setup_host)
|
||||||
|
|
||||||
- name: Setup RPC MQ Service (Qdrouterd)
|
- name: Setup RPC MQ Service (Qdrouterd)
|
||||||
delegate_to: "{{ _oslomsg_rpc_setup_host }}"
|
delegate_to: "{{ _oslomsg_rpc_setup_host }}"
|
||||||
|
|
Loading…
Reference in New Issue