2
0
mirror of https://github.com/xcat2/confluent.git synced 2024-11-25 19:10:10 +00:00

Fix chained smm discovery on cumulus

This commit is contained in:
Jarrod Johnson 2020-09-14 11:02:00 -04:00
parent 7bdf7afb80
commit 9828ea5898
2 changed files with 8 additions and 3 deletions

View File

@ -1020,9 +1020,13 @@ def eval_node(cfg, handler, info, nodename, manual=False):
if nl:
# The candidate nodename is the head of a chain, we must
# validate the smm certificate by the switch
macmap.get_node_fingerprints(nodename, cfg)
util.cert_matches(fprint, handler.https_cert)
return
fprints = macmap.get_node_fingerprints(nodename, cfg)
for fprint in fprints:
if util.cert_matches(fprint[0], handler.https_cert):
if not discover_node(cfg, handler, info,
nodename, manual):
pending_nodes[nodename] = info
return
if (info.get('maccount', False) and
not handler.discoverable_by_switch(info['maccount'])):
errorstr = 'The detected node {0} was detected using switch, ' \

View File

@ -199,6 +199,7 @@ def _extract_neighbor_data_affluent(switch, user, password, cfm, lldpdata):
'port': record['localport'],
'peerid': peerid,
}
_extract_extended_desc(portdata, portdata['peerdescription'], True)
_neighbypeerid[peerid] = portdata
lldpdata[localport] = portdata
neighdata[switch] = lldpdata