browbeat/ansible/gather/roles/compute/tasks/main.yml
Joe Talerico 74a1db4cde ovsdb Metadata
Add neutron-ovs-agent ovsdb information (native vs vsctl)

Change-Id: I72bbc80485d95d8a4be3a1d0c185cee4cbee6d43
2016-05-17 12:31:17 -04:00

27 lines
814 B
YAML

---
#
# Compute Tasks for gathering facts
#
- name: Get ovs version
shell: ovs-vswitchd --version | grep vSwitch | awk {'print$4'}
register: ovs_version
- name: Set ovs version fact
set_fact:
openstack_ovs_version: "{{ ovs_version.stdout }}"
- name: Get neutron ovs agent ovsdb setting
shell: crudini --get /etc/neutron/plugins/ml2/openvswitch_agent.ini ovs ovsdb_interface
register: ovsdb_status
ignore_errors: true
- name: Set Neutron OVS ovsdb fact
set_fact:
openstack_neutron_ovsdb: "{{ ovsdb_status.stdout }}"
when: (ovsdb_status.stdout.find('native') != -1 or ovsdb_status.stdout.find('vsctl') != -1)
- name: Set Neutron OVS ovsdb fact
set_fact:
openstack_neutron_ovsdb: "vsctl"
when: (ovsdb_status.stdout.find('native') == -1 and ovsdb_status.stdout.find('vsctl') == -1)