Listen RabbitMQ on all available container networks
For usecase with Trove, it is important that rabbit listen on dbaas interface, which is not the case with current setup. That from other side exposes risk of listening on not intended interfaces, but we assume that no "wrong" networks should be passed inside RabbitMQ containers. Change-Id: I1559e63e8cf1c767dc2d14940f0d04d52a372242
This commit is contained in:
parent
95def0b6c2
commit
99e70d97ea
@ -14,9 +14,13 @@
|
||||
# limitations under the License.
|
||||
|
||||
rabbitmq_port_bindings: |-
|
||||
{%- set _rabbitmq_port_bindings = {} %}
|
||||
{%- set _ = _rabbitmq_port_bindings.update({ 'ssl_listeners': { management_address: '5671' } }) %}
|
||||
{%- set _ = _rabbitmq_port_bindings.update({ 'tcp_listeners': { management_address: '5672' } }) %}
|
||||
{%- set _rabbitmq_port_bindings = {'ssl_listeners': {}, 'tcp_listeners': {}} %}
|
||||
{%- for network, data in container_networks.items() %}
|
||||
{%- if 'address' in data %}
|
||||
{%- set _ = _rabbitmq_port_bindings['ssl_listeners'].update({ container_networks[network]['address']: '5671' }) %}
|
||||
{%- set _ = _rabbitmq_port_bindings['tcp_listeners'].update({ container_networks[network]['address']: '5672' }) %}
|
||||
{%- endif %}
|
||||
{%- endfor %}
|
||||
{{ _rabbitmq_port_bindings }}
|
||||
|
||||
rabbitmq_management_bind_address: "{{ management_address }}"
|
||||
|
Loading…
x
Reference in New Issue
Block a user