aboutsummaryrefslogtreecommitdiffstats
path: root/deploy/adapters/ansible/roles/odl_cluster/tasks/main.yml
blob: 2254f11ff980c7de49255478282c1a34732c016d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
---
- include_vars: "{{ ansible_os_family }}.yml"

- name: Install ODL Cluster on Controller
  include: odl_controller.yml
  when: inventory_hostname in groups['odl']

- name: Install ODL Cluster on Compute
  include: openvswitch.yml
  when: groups['odl']|length !=0 and inventory_hostname not in groups['odl']

- meta: flush_handlers

- name: check out new flow table if enable
  shell: ovs-ofctl --protocol=OpenFlow13 dump-flows br-prv | grep CONTROLLER; while [ $? -ne 0 ]; do sleep 10; ovs-ofctl --protocol=OpenFlow13 dump-flows br-prv | grep CONTROLLER; done
  when: groups['odl']|length !=0

- name: remove controller from br-prv
  shell: ovs-vsctl del-controller br-prv;
  when: groups['odl']|length !=0