mirror of
https://opendev.org/x/pyghmi
synced 2024-12-25 12:41:37 +00:00
Rework get description to enable it to work fer XCC3
Change-Id: I3c1fdb74bd68571e81963037bc339bff8228ccea
This commit is contained in:
parent
74b2e6da48
commit
b6776ce2ee
@ -1078,7 +1078,7 @@ class Command(object):
|
||||
return self._oem
|
||||
|
||||
def get_description(self):
|
||||
return self.oem.get_description()
|
||||
return self.oem.get_description(self)
|
||||
|
||||
def get_event_log(self, clear=False):
|
||||
bmcinfo = self._do_web_request(self._bmcurl)
|
||||
|
@ -519,7 +519,7 @@ class OEMHandler(object):
|
||||
def detach_remote_media(self):
|
||||
return None
|
||||
|
||||
def get_description(self):
|
||||
def get_description(self, fishclient):
|
||||
return {}
|
||||
|
||||
def get_firmware_inventory(self, components, fishclient):
|
||||
|
@ -579,7 +579,7 @@ class OEMHandler(generic.OEMHandler):
|
||||
summary['badreadings'] = fallbackdata
|
||||
return summary
|
||||
|
||||
def get_description(self):
|
||||
def get_description(self, fishclient):
|
||||
description = self._do_web_request('/DeviceDescription.json')
|
||||
if description:
|
||||
description = description[0]
|
||||
|
@ -4,6 +4,12 @@ import pyghmi.exceptions as pygexc
|
||||
|
||||
class OEMHandler(generic.OEMHandler):
|
||||
|
||||
def get_description(self, fishclient):
|
||||
bmcstgs = fishclient._do_web_request('/redfish/v1/Managers/1/Oem/Lenovo/BMCSettings')
|
||||
heightu = bmcstgs.get('Attributes', {}).get('ServerConfigHeightU')
|
||||
return {'height': heightu}
|
||||
|
||||
|
||||
def get_system_configuration(self, hideadvanced=True, fishclient=None):
|
||||
stgs = self._getsyscfg(fishclient)[0]
|
||||
outstgs = {}
|
||||
|
Loading…
Reference in New Issue
Block a user