Set ovn hostname using nodename facts

Ansible hostname facts using short hostname which may not work for
other senario where compute hostname is set to FQDN. OVN required
ovs set hostname and compute hostname should be same.

Change-Id: I585f73551c5a90841dcf2d1dd94a3e1fc90b04ac
This commit is contained in:
Satish Patel 2021-08-09 20:19:57 +00:00 committed by Jonathan Rosser
parent e2f22f7b79
commit 1403c6308b

View File

@ -15,7 +15,7 @@
# limitations under the License.
- name: Set openvswitch hostname
command: "ovs-vsctl set open_vswitch . external-ids:hostname='{{ ansible_facts['hostname'] }}'"
command: "ovs-vsctl set open_vswitch . external-ids:hostname='{{ ansible_facts['nodename'] }}'"
when:
- (neutron_services['neutron-ovn-northd']['group'] in group_names) or
(neutron_services['neutron-ovn-controller']['group'] in group_names)