mirror of
https://github.com/xcat2/confluent.git
synced 2024-11-26 03:19:48 +00:00
Include absent devices in the json of nodeinventory
This commit is contained in:
parent
efd5732682
commit
b877a95645
@ -130,8 +130,13 @@ try:
|
||||
for inv in res['databynode'][node]['inventory']:
|
||||
prefix = inv['name']
|
||||
if not inv['present']:
|
||||
if not filters and not options.json:
|
||||
print '{0}: {1}: Not Present'.format(node, prefix)
|
||||
if not filters:
|
||||
if options.json:
|
||||
if node not in databynode:
|
||||
databynode[node] = {}
|
||||
databynode[node][prefix] = inv
|
||||
else:
|
||||
print '{0}: {1}: Not Present'.format(node, prefix)
|
||||
continue
|
||||
info = inv['information']
|
||||
info.pop('board_extra', None)
|
||||
|
Loading…
Reference in New Issue
Block a user