645a3935ee
This sets up a default 'br-infra' bridge between nodes in a multi-node job. Two groups are expected in order for this to be set up: - switch - peers The 'switch' group, with only one expected member, will be set up as the switch node while the 'peers' group will be connected to the switch node with virtual ports. The default settings such as the bridge name, the IP range used, the MTU and so on can be overridden at the job level by setting vars. Change-Id: If5a3f512837e5b235bd2f6dbfdbb454435aa983e
26 lines
700 B
YAML
26 lines
700 B
YAML
- name: Configure a multi node environment
|
|
hosts: all
|
|
tasks:
|
|
# TODO: Add groups['all'] | length > 1 conditional when the truncated JSON
|
|
# issue is resolved, see:
|
|
# - https://github.com/ansible/ansible/issues/30385
|
|
# - https://review.openstack.org/#/c/504238/
|
|
- name: Set up multi-node known hosts
|
|
include_role:
|
|
name: multi-node-known-hosts
|
|
|
|
- name: Set up multi-node hosts file
|
|
include_role:
|
|
name: multi-node-hosts-file
|
|
|
|
- name: Set up multi-node firewall
|
|
include_role:
|
|
name: multi-node-firewall
|
|
|
|
- name: Configure multi-node networking switch and peer nodes
|
|
hosts:
|
|
- switch
|
|
- peers
|
|
roles:
|
|
- multi-node-bridge
|