mirror of
https://github.com/xcat2/confluent.git
synced 2025-02-11 08:15:24 +00:00
Merge branch 'master' into passfilehandle
This commit is contained in:
commit
0ff9d5dc7e
@ -263,7 +263,11 @@ def list_matching_macs(options, session, node=None, checknode=True):
|
||||
return [options.mac.replace(':', '-')]
|
||||
else:
|
||||
path += 'by-mac/'
|
||||
return [x['item']['href'] for x in session.read(path)]
|
||||
ret = []
|
||||
for x in session.read(path):
|
||||
if 'item' in x and 'href' in x['item']:
|
||||
ret.append(x['item', 'href'])
|
||||
return ret
|
||||
|
||||
def assign_discovery(options, session, needid=True):
|
||||
abort = False
|
||||
|
@ -74,7 +74,7 @@ if args[0] == 'restore':
|
||||
for targdir in os.walk('/etc/confluent'):
|
||||
os.chown(targdir[0], owner, group)
|
||||
for f in targdir[2]:
|
||||
os.chown(os.patht.join(targdir[0], f), owner, group)
|
||||
os.chown(os.path.join(targdir[0], f), owner, group)
|
||||
except Exception as e:
|
||||
print(str(e))
|
||||
sys.exit(1)
|
||||
|
@ -814,10 +814,10 @@ def get_smm_neighbor_fingerprints(smmaddr, cv):
|
||||
neighs = wc.grab_json_response('/scripts/neighdata.json')
|
||||
if not neighs:
|
||||
return
|
||||
for idx in (4, 5):
|
||||
if 'sha256' not in neighs[idx]:
|
||||
for neigh in neighs:
|
||||
if 'sha256' not in neigh:
|
||||
continue
|
||||
yield 'sha256$' + b64tohex(neighs[idx]['sha256'])
|
||||
yield 'sha256$' + b64tohex(neigh['sha256'])
|
||||
|
||||
|
||||
def get_nodename(cfg, handler, info):
|
||||
|
Loading…
x
Reference in New Issue
Block a user