NB SB fuck up
This commit is contained in:
parent
e87205b01f
commit
dede47c8dd
|
@ -105,11 +105,11 @@
|
||||||
- "/tmp/ovn_20.09.0-1_amd64.deb"
|
- "/tmp/ovn_20.09.0-1_amd64.deb"
|
||||||
when: force_new_ovn_download == True
|
when: force_new_ovn_download == True
|
||||||
|
|
||||||
- set_fact: ovn_nb_group_name_rendered="{{hostvars[ansible_hostname].ovn_nb_db_group}}"
|
- set_fact: ovn_sb_group_name_rendered="{{hostvars[ansible_hostname].ovn_sb_db_group}}"
|
||||||
tags: service
|
tags: service
|
||||||
|
|
||||||
- name: Generate OVN NB Connection fact
|
- name: Generate OVN SB Connection fact
|
||||||
set_fact: OVN_NB_Connection="{% for host in groups[ovn_nb_group_name_rendered] %}tcp:{{ hostvars[host].host_loopback_IP }}:6641{% if not loop.last %},{% endif %}{% endfor %}"
|
set_fact: OVN_SB_Connection="{% for host in groups[ovn_sb_group_name_rendered] %}tcp:{{ hostvars[host].host_loopback_IP }}:6642{% if not loop.last %},{% endif %}{% endfor %}"
|
||||||
tags: service
|
tags: service
|
||||||
|
|
||||||
#Install the custom service to start OVS and OVN as required
|
#Install the custom service to start OVS and OVN as required
|
||||||
|
|
|
@ -10,7 +10,7 @@ START(){
|
||||||
hostname=$(hostname)
|
hostname=$(hostname)
|
||||||
loopbackIP={{host_loopback_IP}}
|
loopbackIP={{host_loopback_IP}}
|
||||||
|
|
||||||
echo "Starting OpenVSwitch and OVN on $hostname with $loopbackIP and pointing to OVN controller {{OVN_NB_Connection}}"
|
echo "Starting OpenVSwitch and OVN on $hostname with $loopbackIP and pointing to OVN controller {{OVN_SB_Connection}}"
|
||||||
|
|
||||||
DIR="/var/run/openvswitch/db.sock"
|
DIR="/var/run/openvswitch/db.sock"
|
||||||
if [ -d "$DIR" ]; then
|
if [ -d "$DIR" ]; then
|
||||||
|
@ -23,7 +23,7 @@ START(){
|
||||||
ovs-appctl -t ovsdb-server ovsdb-server/add-remote ptcp:6640
|
ovs-appctl -t ovsdb-server ovsdb-server/add-remote ptcp:6640
|
||||||
|
|
||||||
ovs-vsctl set open . external-ids:ovn-bridge=br-int
|
ovs-vsctl set open . external-ids:ovn-bridge=br-int
|
||||||
ovs-vsctl set open . external-ids:ovn-remote={{OVN_NB_Connection}}
|
ovs-vsctl set open . external-ids:ovn-remote={{OVN_SB_Connection}}
|
||||||
ovs-vsctl set open . external-ids:ovn-encap-type=geneve
|
ovs-vsctl set open . external-ids:ovn-encap-type=geneve
|
||||||
ovs-vsctl set open . external-ids:ovn-encap-ip=$loopbackIP
|
ovs-vsctl set open . external-ids:ovn-encap-ip=$loopbackIP
|
||||||
/usr/share/ovn/scripts/ovn-ctl start_controller
|
/usr/share/ovn/scripts/ovn-ctl start_controller
|
||||||
|
|
Loading…
Reference in New Issue