mirror of
https://github.com/xcat2/confluent.git
synced 2024-11-22 01:22:00 +00:00
Add extended nodeconfig to confluent redfish
This commit is contained in:
parent
7304c8e3b7
commit
1d80e2703c
@ -516,6 +516,12 @@ class IpmiHandler(object):
|
||||
return self.handle_ntp()
|
||||
elif self.element[1:4] == ['management_controller', 'extended', 'all']:
|
||||
return self.handle_bmcconfig()
|
||||
elif self.element[1:4] == ['management_controller', 'extended', 'advanced']:
|
||||
return self.handle_bmcconfig(True)
|
||||
elif self.element[1:4] == ['management_controller', 'extended', 'extra']:
|
||||
return self.handle_bmcconfig(advanced=False, extended=True)
|
||||
elif self.element[1:4] == ['management_controller', 'extended', 'extra_advanced']:
|
||||
return self.handle_bmcconfig(advanced=True, extended=True)
|
||||
elif self.element[1:3] == ['system', 'all']:
|
||||
return self.handle_sysconfig()
|
||||
elif self.element[1:3] == ['system', 'advanced']:
|
||||
@ -1312,12 +1318,15 @@ class IpmiHandler(object):
|
||||
if 'read' == self.op:
|
||||
lc = self.ipmicmd.get_location_information()
|
||||
|
||||
def handle_bmcconfig(self, advanced=False):
|
||||
def handle_bmcconfig(self, advanced=False, extended=False):
|
||||
if 'read' == self.op:
|
||||
try:
|
||||
self.output.put(msg.ConfigSet(
|
||||
self.node,
|
||||
self.ipmicmd.get_bmc_configuration()))
|
||||
if extended:
|
||||
bmccfg = self.ipmicmd.get_extended_bmc_configuration(
|
||||
hideadvanced=(not advanced))
|
||||
else:
|
||||
bmccfg = self.ipmicmd.get_bmc_configuration()
|
||||
self.output.put(msg.ConfigSet(self.node, bmccfg))
|
||||
except Exception as e:
|
||||
self.output.put(
|
||||
msg.ConfluentNodeError(self.node, str(e)))
|
||||
|
Loading…
Reference in New Issue
Block a user