Files
kolla-ansible/ansible/roles/openvswitch/tasks/post-config.yml
Michal Nasiadka 8df6cf4814 openvswitch: move from docker exec to openvswitch_db
Change-Id: Ifee8af246312cad5b68ff1bf2793963bf7028dc8
2021-11-25 05:55:23 +00:00

27 lines
897 B
YAML

---
# NOTE(mnasiadka): external_ids:system-id uniquely identifies a physical system, used by OVN and other controllers
- name: Set system-id
become: true
kolla_toolbox:
user: root
module_name: openvswitch_db
module_args:
table: Open_vSwitch
record: .
col: external_ids
key: system-id
value: "{{ openvswitch_system_id }}"
state: present
- name: Ensuring OVS bridge is properly setup
become: true
command: docker exec openvswitch_db /usr/local/bin/kolla_ensure_openvswitch_configured {{ item.0 }} {{ item.1 }}
register: status
changed_when: status.stdout.find('changed') != -1
when:
- inventory_hostname in groups["network"]
or (inventory_hostname in groups["compute"] and computes_need_external_bridge | bool )
with_together:
- "{{ neutron_bridge_name.split(',') }}"
- "{{ neutron_external_interface.split(',') }}"