diff --git a/ansible/group_vars/all.yml b/ansible/group_vars/all.yml index 8ddb843396..ca573064f1 100644 --- a/ansible/group_vars/all.yml +++ b/ansible/group_vars/all.yml @@ -1012,6 +1012,9 @@ neutron_sriov_physnet_mappings: sriovnet1: "{{ tunnel_interface }}" neutron_enable_tls_backend: "{{ kolla_enable_tls_backend }}" +# Set OVN network availability zones +neutron_ovn_availability_zones: [] + ####################### # Nova options ####################### diff --git a/ansible/roles/ovn-controller/tasks/setup-ovs.yml b/ansible/roles/ovn-controller/tasks/setup-ovs.yml index 82f7829893..5ac61a16b3 100644 --- a/ansible/roles/ovn-controller/tasks/setup-ovs.yml +++ b/ansible/roles/ovn-controller/tasks/setup-ovs.yml @@ -14,7 +14,7 @@ vars: ovn_mappings: "{% for bridge in neutron_bridge_name.split(',') %}physnet{{ loop.index0 + 1 }}:{{ bridge }}{% if not loop.last %},{% endif %}{% endfor %}" ovn_macs: "{% for bridge in neutron_bridge_name.split(',') %}physnet{{ loop.index0 + 1 }}:{{ ovn_base_mac | random_mac(seed=inventory_hostname + bridge) }}{% if not loop.last %},{% endif %}{% endfor %}" - ovn_cms_opts: "{{ 'enable-chassis-as-gw' if inventory_hostname in groups['ovn-controller-network'] else '' }}" + ovn_cms_opts: "{{ 'enable-chassis-as-gw' if inventory_hostname in groups['ovn-controller-network'] else '' }}{{ ',availability-zones=' + neutron_ovn_availability_zones | join(',') if inventory_hostname in groups['ovn-controller-network'] and neutron_ovn_availability_zones }}" become: true kolla_toolbox: container_engine: "{{ kolla_container_engine }}" diff --git a/releasenotes/notes/neutron_ovn_availability_zones-0271d74dbc4f957e.yaml b/releasenotes/notes/neutron_ovn_availability_zones-0271d74dbc4f957e.yaml new file mode 100644 index 0000000000..b03fee5549 --- /dev/null +++ b/releasenotes/notes/neutron_ovn_availability_zones-0271d74dbc4f957e.yaml @@ -0,0 +1,7 @@ +--- +features: + - | + With the new ``neutron_ovn_availability_zones`` parameter it is possible + to define network availability zones for OVN. Further details can be found + in the Neutron OVN documentation: + https://docs.openstack.org/neutron/latest/admin/ovn/availability_zones.html#how-to-configure-it