commit | 9516f41f9295170ad5d59ded36584d22776417d5 | [log] [tgz] |
---|---|---|
author | George Liu <liuxiwei@inspur.com> | Thu Sep 29 17:21:41 2022 +0800 |
committer | Gunnar Mills <gmills@us.ibm.com> | Thu Jul 13 03:01:21 2023 +0000 |
tree | 6e7289ba637b4c9e4be8bd13d436aea0eb63faa1 | |
parent | 2c6ffdb08b2207ff7c31041f77cc3755508d45c4 [diff] |
Implements FanCollection schema The FanCollection schema is a resource in Redifsh version 2022.2 [1] that represents the management properties for the monitoring and management of cooling fans implemented by Redfish [2]. This commit retrieves the fan collection by obtaining the endpoints of the `cooled_by` association. The `cooled_by` association represents the relationship between a chassis and the fans responsible for providing cooling to the chassis. ref: [1] https://www.dmtf.org/sites/default/files/standards/documents/DSP0268_2022.2.pdf [2] http://redfish.dmtf.org/schemas/v1/Fan.v1_3_0.json Redfish validator is currently failing. In order for the validator to pass, it is necessary to merge this commit with https://gerrit.openbmc.org/c/openbmc/bmcweb/+/57559 Tested: 1. doGet method to get FanCollection ``` curl -k -H "X-Auth-Token: $token" -X GET https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans", "@odata.type": "#FanCollection.FanCollection", "Description": "The collection of Fan resource instances chassis", "Members": [ { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan5" }, { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan4" }, { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan3" }, { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan2" }, { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1" }, { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan0" } ], "Members@odata.count": 6, "Name": "Fan Collection" } 2. Input the wrong chassisId with the doGet method curl -k https://${bmc}/redfish/v1/Chassis/chassis11/ThermalSubsystem/Fans { "error": { "@Message.ExtendedInfo": [ { "@odata.type": "#Message.v1_1_1.Message", "Message": "The requested resource of type Chassis named 'chassis11' was not found.", "MessageArgs": [ "Chassis", "chassis11" ], "MessageId": "Base.1.13.0.ResourceNotFound", "MessageSeverity": "Critical", "Resolution": "Provide a valid resource identifier and resubmit the request." } ], "code": "Base.1.13.0.ResourceNotFound", "message": "The requested resource of type Chassis named 'chassis11' was not found." } } ``` Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: If5e9ff5655f444694c7ca1aea95d45e2c9222625 Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>
This component attempts to be a "do everything" embedded webserver for OpenBMC.
The webserver implements a few distinct interfaces:
bmcweb at a protocol level supports http and https. TLS is supported through OpenSSL.
Bmcweb supports multiple authentication protocols:
Each of these types of authentication is able to be enabled or disabled both via runtime policy changes (through the relevant Redfish APIs) or via configure time options. All authentication mechanisms supporting username/password are routed to libpam, to allow for customization in authentication implementations.
All authorization in bmcweb is determined at routing time, and per route, and conform to the Redfish PrivilegeRegistry.
*Note: Non-Redfish functions are mapped to the closest equivalent Redfish privilege level.
bmcweb is configured per the meson build files. Available options are documented in meson_options.txt
meson setup builddir ninja -C builddir
If any of the dependencies are not found on the host system during configuration, meson will automatically download them via its wrap dependencies mentioned in bmcweb/subprojects
.
bmcweb relies on some on-system data for storage of persistent data that is internal to the process. Details on the exact data stored and when it is read/written can seen from the persistent_data
namespace.
When SSL support is enabled and a usable certificate is not found, bmcweb will generate a self-signed a certificate before launching the server. Please see the bmcweb source code for details on the parameters this certificate is built with.
bmcweb is capable of aggregating resources from satellite BMCs. Refer to AGGREGATION.md for more information on how to enable and use this feature.