The networks must have a global lscope.
This commit is contained in:
parent
6d0f05f555
commit
df37f5f5b2
|
@ -5,15 +5,16 @@
|
||||||
docker_network:
|
docker_network:
|
||||||
name: '{{ item }}'
|
name: '{{ item }}'
|
||||||
driver: overlay
|
driver: overlay
|
||||||
|
scope: swarm
|
||||||
with_items: '{{ docker_swarm_haproxy_networks }}'
|
with_items: '{{ docker_swarm_haproxy_networks }}'
|
||||||
|
|
||||||
- name: Connect haproxy to the overlay networks
|
# - name: Connect haproxy to the overlay networks
|
||||||
docker_network:
|
# docker_network:
|
||||||
name: '{{ item }}'
|
# name: '{{ item }}'
|
||||||
connected:
|
# connected:
|
||||||
- 'haproxy_haproxy'
|
# - 'haproxy_haproxy'
|
||||||
appends: yes
|
# appends: yes
|
||||||
with_items: '{{ docker_swarm_haproxy_networks }}'
|
# with_items: '{{ docker_swarm_haproxy_networks }}'
|
||||||
|
|
||||||
when: docker_swarm_manager_main_node | bool
|
when: docker_swarm_manager_main_node | bool
|
||||||
tags: [ 'haproxy', 'docker_haproxy', 'docker_swarm', 'docker', 'docker_network' ]
|
tags: [ 'haproxy', 'docker_haproxy', 'docker_swarm', 'docker', 'docker_network' ]
|
||||||
|
|
Loading…
Reference in New Issue