Browse Source

Skip port if it's on the OVN MAC Net

Skip ports for which the network_id is not in
'networks_by_id'. This means it is a OVN bridge MAC
port and should be ignored.

This change is the original patch, and the partial
revert squashed in.

Related: blueprint network-data-v2-ports
Closes-Bug: #1928469
Depends-On: https://review.opendev.org/790687
Change-Id: Ife65326509e1d5fe7689c1baec17d902ec848c0d
(cherry picked from commit 14441478f9)
(cherry picked from commit d328637713)
changes/37/791937/2
Harald Jensås 5 months ago
parent
commit
0a7cfe3934
  1. 4
      tripleo_common/inventory.py

4
tripleo_common/inventory.py

@ -132,6 +132,10 @@ class NeutronData(object):
ports_by_role_and_host = {}
for port in self.ports:
# Ignore ports in networks we ignore, i.e the OVN Bridge MAC net
if port.network_id not in self.networks_by_id:
continue
tags = self._tags_to_dict(port.tags)
# In case of missing required tags, raise an error.
# neutron is useless as a inventory source in this case.

Loading…
Cancel
Save