mirror of
https://opendev.org/x/pyghmi
synced 2026-08-25 08:06:48 +00:00
Merge "Add http boot dev"
This commit is contained in:
@@ -53,6 +53,7 @@ boot_devices = {
|
||||
'net': 4,
|
||||
'network': 4,
|
||||
'pxe': 4,
|
||||
'http': 4,
|
||||
'hd': 8,
|
||||
'safe': 0xc,
|
||||
'cd': 0x14,
|
||||
|
||||
@@ -60,6 +60,7 @@ boot_devices_read = {
|
||||
'Pxe': 'network',
|
||||
'Usb': 'usb',
|
||||
'SDCard': 'sdcard',
|
||||
'UefiHttp': 'http',
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -107,6 +107,7 @@ boot_devices_write = {
|
||||
'net': 'Pxe',
|
||||
'network': 'Pxe',
|
||||
'pxe': 'Pxe',
|
||||
'http': 'UefiHttp',
|
||||
'hd': 'Hdd',
|
||||
'usb': 'Usb',
|
||||
'cd': 'Cd',
|
||||
@@ -129,6 +130,7 @@ boot_devices_read = {
|
||||
'Pxe': 'network',
|
||||
'Usb': 'usb',
|
||||
'SDCard': 'sdcard',
|
||||
'UefiHttp': 'http',
|
||||
}
|
||||
|
||||
|
||||
@@ -736,6 +738,10 @@ class OEMHandler(object):
|
||||
raise exc.InvalidParameterValue('Unsupported device %s'
|
||||
% repr(bootdev))
|
||||
bootdev = boot_devices_write.get(bootdev, bootdev)
|
||||
if bootdev == 'UefiHttp':
|
||||
allowvals = fishclient.sysinfo.get('Boot', {}).get('BootSourceOverrideTarget@Redfish.AllowableValues', [])
|
||||
if bootdev not in allowvals:
|
||||
bootdev = 'Pxe'
|
||||
if bootdev == 'None':
|
||||
payload = {'Boot': {'BootSourceOverrideEnabled': 'Disabled'}}
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user