commit | c6a620f2e01ce5f1551ecc4455624654282d79c7 | [log] [tgz] |
---|---|---|
author | George Liu <liuxiwei@inspur.com> | Fri Apr 10 17:18:11 2020 +0800 |
committer | George Liu <liuxiwei@inspur.com> | Fri Apr 24 09:28:00 2020 +0000 |
tree | d4d5e2a65a64874806ffae6c6b390243265684cf | |
parent | 3946028d2d3143109bb562841efce3e094c70c0b [diff] |
Map policy restore D-Bus interface to Redfish Tested: curl -k -H "X-Auth-Token: $token" https://${bmc}/redfish/v1/Systems/system { "@odata.id": "/redfish/v1/Systems/system", "@odata.type": "#ComputerSystem.v1_6_0.ComputerSystem", ... ... "PowerRestorePolicy": "AlwaysOff", ... ... } curl -k -H "X-Auth-Token: $token" -X PATCH -d '{"PowerRestorePolicy":"AlwaysOn"}' https://${bmc}/redfish/v1/Systems/system curl -k -H "X-Auth-Token: $token" https://${bmc}/redfish/v1/Systems/system { "@odata.id": "/redfish/v1/Systems/system", "@odata.type": "#ComputerSystem.v1_6_0.ComputerSystem", ... ... "PowerRestorePolicy": "AlwaysOn", ... ... } curl -k -H "X-Auth-Token: $token" -X PATCH -d '{"PowerRestorePolicy":"TestPolicy"}' https://${bmc}/redfish/v1/Systems/system { "error": { "@Message.ExtendedInfo": [ { "@odata.type": "#Message.v1_0_0.Message", "Message": "The request failed due to an internal service error. The service is still operational.", "MessageArgs": [], "MessageId": "Base.1.4.0.InternalError", "Resolution": "Resubmit the request. If the problem persists, consider resetting the service.", "Severity": "Critical" } ], "code": "Base.1.4.0.InternalError", "message": "The request failed due to an internal service error. The service is still operational." } } Passed the validator: VERBO - ServiceRoot -> Systems.Systems -> Members.ComputerSystem#0, ComputerSystem.v1_10_0, ComputerSystem VERBO - @odata.id PASS VERBO - @odata.type PASS VERBO - Actions complex VERBO - Bios PASS VERBO - Boot complex VERBO - Description PASS VERBO - Id PASS VERBO - Links complex VERBO - LogServices PASS VERBO - Memory PASS VERBO - MemorySummary complex VERBO - Name PASS VERBO - PowerRestorePolicy PASS ... ... Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: I75155c5cb930d6c4d9d5aad39f3315506db28e38
This component attempts to be a "do everything" embedded webserver for openbmc.
At this time, the webserver implements a few interfaces:
BMCWeb is configured by setting -D
flags that correspond to options in bmcweb/CMakeLists.txt
and then compiling. For example, cmake -DBMCWEB_ENABLE_KVM=NO ...
followed by make
. The option names become C++ preprocessor symbols that control which code is compiled into the program.
When BMCWeb starts running, it reads persistent configuration data (such as UUID and session data) from a local file. If this is not usable, it generates a new configuration.
When BMCWeb SSL support is enabled and a usable certificate is not found, it will generate a self-sign a certificate before launching the server. The keys are generated by the secp384r1
algorithm. The certificate
C=US, O=OpenBMC, CN=testhost
,SHA-256
algorithm.