This commit implements the same features as 051b285aaa9b595ea9513ff5fa197eb830b942c1, with some differences:
- Added unit tests for all new features
- Added interfaces to `modules/bmc/base.rb`
- Cleared up some ambiguous method names
- Changed some unit test stubs to expects
- Fixed bugs in the original implementation
New API methods:
- GET /bmc/:host/fru Shows available actions: "list", "serial", "manufacturer", "model", and "asset_tag"
- GET /bmc/:host/bmc Shows available actions: "info", "guid", and "version"
- GET /bmc/:host/sensors Shows available actions: "list", "count", "names", "fanlist", "templist", and "get"
- GET /bmc/:host/lan/snmp Shows BMC host's SNMP community string
- GET /bmc/:host/lan/vlanid Shows BMC host's VLAN ID
- GET /bmc/:host/lan/ipsrc Shows whether BMC host's LAN was configured "static" or "dhcp"
- GET /bmc/:host/lan/print Shows BMC hosts's LAN configuration
- PUT /bmc/:host/chassis/power/reset Performs power reset on chassis
- GET /bmc/:host/fru/list Shows all of host's FRU information. Includes workaround for undocumented IBM/Lenovo IPMI bug.
- GET /bmc/:host/fru/serial Shows host's serial number
- GET /bmc/:host/fru/manufacturer Shows host's manufacturer
- GET /bmc/:host/fru/model Shows host's product model
- GET /bmc/:host/fru/asset_tag Shows host's asset tag string, if Rubyipmi has this method. It's in the spec, but doesn't seem to be implemented today. See logicminds/rubyipmi/blob/master/spec/unit/ipmitool/fru_spec.rb
- GET /bmc/:host/bmc/info Shows information about the BMC
- GET /bmc/:host/bmc/guid Shows system's GUID
- GET /bmc/:host/version Shows BMC's version
- PUT /bmc/:host/bmc/reset?type=warm Performs warm reset on BMC
- PUT /bmc/:host/bmc/reset?type=cold Performs cold reset on BMC
- GET /bmc/:host/sensors/list Shows all of host's sensors
- GET /bmc/:host/sensors/count Shows number of sensors on host
- GET /bmc/:host/sensors/names Shows list of sensor names on host
- GET /bmc/:host/sensors/fanlist Shows all of host's fan sensors
- GET /bmc/:host/sensors/templist Shows all of host's temperature sensors
- GET /bmc/:host/sensors/get Shows available option "sensor" for this action
- GET /bmc/:host/sensors/get/:sensor Shows information about sensor :sensor on host
Related issues
Feature #2595: Expose more existing rubyipmi features as BMC smart-proxy APIs
Fixes #2595 - Add more Rubyipmi methods to BMC API
Replaces: theforeman/smart-proxy#505
Replaces: 051b285aaa9b595ea9513ff5fa197eb830b942c1
This commit implements the same features as
051b285aaa9b595ea9513ff5fa197eb830b942c1, with some differences:
New API methods: