Varsha f18831163e Add Drive resource support
This change adds basic Redfish Drive resource support to the
dynamic Redfish emulator. As of this patch, the only backend
for the Redfish Drives implemented is static config (Flask)
file.

Change-Id: I867cea6263a8a934dd90169b783893be46d75d36
2019-09-04 20:32:12 +05:30

31 lines
1.1 KiB
JSON

{
"@odata.type": "#Drive.v1_4_0.Drive",
"Id": {{ drive['Id']|string|tojson }},
"Name": {{ drive['Name']|string|tojson }},
"IndicatorLED": "Lit",
"Model": "C123",
"Revision": "100A",
"Status": {
"@odata.type": "#Resource.Status",
"State": "Enabled",
"Health": "OK"
},
"CapacityBytes": {{ drive['CapacityBytes'] }},
"FailurePredicted": false,
"Protocol": {{ drive['Protocol']|string|tojson }},
"MediaType": "HDD",
"Manufacturer": "Contoso",
"SerialNumber": "1234570",
"PartNumber": "C123-1111",
"HotspareType": "Global",
"EncryptionAbility": "SelfEncryptingDrive",
"EncryptionStatus": "Unlocked",
"RotationSpeedRPM": 15000,
"BlockSizeBytes": 512,
"CapableSpeedGbs": 12,
"NegotiatedSpeedGbs": 12,
"@odata.context": "/redfish/v1/$metadata#Drive.Drive",
"@odata.id": {{ "/redfish/v1/Systems/%s/Storage/%s/Drives/%s"|format(identity, storage_id, drive['Id'])|tojson }},
"@Redfish.Copyright": "Copyright 2014-2017 Distributed Management Task Force, Inc. (DMTF). For the full DMTF copyright policy, see http://www.dmtf.org/about/policies/copyright."
}