mirror of
https://github.com/xcat2/confluent.git
synced 2025-01-16 20:57:53 +00:00
Include absent devices in the json of nodeinventory
This commit is contained in:
parent
0d4b1a4213
commit
173f1eaf7e
@ -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…
x
Reference in New Issue
Block a user