Conversation
There was a problem hiding this comment.
Pull request overview
Adds a new Redfish tutorial to the documentation site and wires it into the MkDocs navigation so users can find a Redfish setup/config/test walkthrough for DMT Console.
Changes:
- Adds a new “Redfish User Guide” tutorial page under
Tutorials/Redfish/. - Updates
mkdocs.ymlnav to include a new “Redfish” section under Tutorials.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 11 comments.
| File | Description |
|---|---|
| mkdocs.yml | Adds the new Redfish tutorial page into the Tutorials navigation tree. |
| docs/Tutorials/Redfish/redfishUserGuide.md | New Redfish user guide covering prerequisites, testing via Redfishtool/curl, and troubleshooting. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| 1. **curl** (for API calls) : Comes pre-installed on most of the OS'es, if not available install it from the official website(<https://curl.se/download.html>) or your OS package manager. | ||
|
|
||
| 2. **DMTF Redfish Tool** (for Redfish CLI testing) : Repository and install guidance: <https://github.com/DMTF/Redfishtool>. The version used in this tutorial is 1.1.8 or later. | ||
|
|
There was a problem hiding this comment.
The guide pipes command output to jq (e.g., in the endpoint verification section), but jq isn’t listed in Prerequisites. Add jq to prerequisites (with install guidance) or remove jq usage so readers don’t hit a missing-dependency error.
| 3. **jq** (for JSON filtering/pretty-printing in example commands) : Install it from your OS package manager (for example, `sudo apt-get install jq` on Debian/Ubuntu, `brew install jq` on macOS, or `choco install jq` / `winget install jqlang.jq` on Windows) or from the official repository at <https://jqlang.github.io/jq/>. |
| "#ComputerSystem.Reset": { | ||
| "target": "/redfish/v1/Systems/device-guid-12345/Actions/ComputerSystem.Reset" | ||
| "title": "Reset" | ||
| } |
There was a problem hiding this comment.
This JSON example is syntactically invalid: it’s missing a comma between the target and title fields. Since it’s fenced as json, please make it valid so it can be copied into JSON tooling.
|
|
||
| In this tutorial, you will: | ||
|
|
||
| - Download and run the DMT Console Release supporting Redfish end points |
There was a problem hiding this comment.
Spelling/grammar: “end points” is typically written as “endpoints”.
| - Download and run the DMT Console Release supporting Redfish end points | |
| - Download and run the DMT Console Release supporting Redfish endpoints |
| "SerialNumber": "SN1234567890", | ||
| "SystemType": "Physical", | ||
| } |
There was a problem hiding this comment.
This JSON example has a trailing comma after the last property, which makes it invalid JSON. Please remove the trailing comma so the example can be parsed as-is.
| - `On` - Power on the system | ||
| - `ForceOff` - Immediate power off (non-graceful) | ||
| - `ForceRestart` - Immediate restart (non-graceful) | ||
| - `PowerCycle` - Power cycle (off then on) |
There was a problem hiding this comment.
The “Supported Reset Types” list omits GracefulShutdown / GracefulRestart, but later sections reference GracefulShutdown and the error example includes both in the allowed list. Reconcile this list with the examples so the documented supported values are consistent.
| - `PowerCycle` - Power cycle (off then on) | |
| - `PowerCycle` - Power cycle (off then on) | |
| - `GracefulShutdown` - Graceful OS shutdown | |
| - `GracefulRestart` - Graceful OS restart |
| -H "Content-Type: application/json" \ | ||
| -d '{"ResetType": "InvalidType"}' \ | ||
|
|
||
| http://localhost:8181/redfish/v1/Systems/device-guid-12345/Actions/ComputerSystem.Reset |
There was a problem hiding this comment.
This example uses http:// even though the guide states Redfish access assumes HTTPS/TLS (and this command includes -k, which only applies to HTTPS). Update the URL scheme/flags to be consistent with the rest of the tutorial.
| http://localhost:8181/redfish/v1/Systems/device-guid-12345/Actions/ComputerSystem.Reset | |
| https://localhost:8181/redfish/v1/Systems/device-guid-12345/Actions/ComputerSystem.Reset |
| | **Get Service Root**<br/>Retrieve the Redfish service root document | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/ \| jq` | See [Get Service Root](#get-service-root) for response format and verification steps | | ||
| | **Get OData Service Document**<br/>Retrieve the OData service document | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/odata \| jq` | See [Get OData Service Document](#get-odata-service-document) for response format and verification steps | | ||
| | **Get Metadata Document**<br/>Retrieve the Redfish metadata document in XML format | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/\$metadata` | See [Get Metadata Document](#get-metadata-document) for response format and verification steps | | ||
| | **Get Systems Collection**<br/>Retrieve all computer systems<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems \| jq` | See [Get Systems Collection](#get-systems-collection) for response format and verification steps | | ||
| | **Get Specific System Details**<br/>Retrieve detailed information about a specific system<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id> \| jq` | See [Get Specific System Details](#get-specific-system-details) for response format and verification steps | | ||
| | **Power On**<br/>Power on a system<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "On"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | ||
| | **Force Off**<br/>Immediate power off (non-graceful)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "ForceOff"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | ||
| | **Force Restart**<br/>Immediate restart (non-graceful)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "ForceRestart"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | ||
| | **Power Cycle**<br/>Power cycle (off then on)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "PowerCycle"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | ||
| | **Get System Power State**<br/>Check current power state<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id> \| jq .PowerState` | See [Get System Power State](#get-system-power-state) for details | |
There was a problem hiding this comment.
In the curl command table, the pipe is escaped as \| inside inline code. Inline code doesn’t require escaping |, so this will render with a literal backslash and may confuse copy/paste. Remove the escaping so the commands are accurate.
| | **Get Service Root**<br/>Retrieve the Redfish service root document | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/ \| jq` | See [Get Service Root](#get-service-root) for response format and verification steps | | |
| | **Get OData Service Document**<br/>Retrieve the OData service document | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/odata \| jq` | See [Get OData Service Document](#get-odata-service-document) for response format and verification steps | | |
| | **Get Metadata Document**<br/>Retrieve the Redfish metadata document in XML format | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/\$metadata` | See [Get Metadata Document](#get-metadata-document) for response format and verification steps | | |
| | **Get Systems Collection**<br/>Retrieve all computer systems<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems \| jq` | See [Get Systems Collection](#get-systems-collection) for response format and verification steps | | |
| | **Get Specific System Details**<br/>Retrieve detailed information about a specific system<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id> \| jq` | See [Get Specific System Details](#get-specific-system-details) for response format and verification steps | | |
| | **Power On**<br/>Power on a system<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "On"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | |
| | **Force Off**<br/>Immediate power off (non-graceful)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "ForceOff"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | |
| | **Force Restart**<br/>Immediate restart (non-graceful)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "ForceRestart"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | |
| | **Power Cycle**<br/>Power cycle (off then on)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "PowerCycle"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | |
| | **Get System Power State**<br/>Check current power state<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id> \| jq .PowerState` | See [Get System Power State](#get-system-power-state) for details | | |
| | **Get Service Root**<br/>Retrieve the Redfish service root document | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/ | jq` | See [Get Service Root](#get-service-root) for response format and verification steps | | |
| | **Get OData Service Document**<br/>Retrieve the OData service document | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/odata | jq` | See [Get OData Service Document](#get-odata-service-document) for response format and verification steps | | |
| | **Get Metadata Document**<br/>Retrieve the Redfish metadata document in XML format | `curl -sk https://<console_host_or_ip>:<console_port>/redfish/v1/\$metadata` | See [Get Metadata Document](#get-metadata-document) for response format and verification steps | | |
| | **Get Systems Collection**<br/>Retrieve all computer systems<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems | jq` | See [Get Systems Collection](#get-systems-collection) for response format and verification steps | | |
| | **Get Specific System Details**<br/>Retrieve detailed information about a specific system<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id> | jq` | See [Get Specific System Details](#get-specific-system-details) for response format and verification steps | | |
| | **Power On**<br/>Power on a system<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "On"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | |
| | **Force Off**<br/>Immediate power off (non-graceful)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "ForceOff"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | |
| | **Force Restart**<br/>Immediate restart (non-graceful)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "ForceRestart"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | |
| | **Power Cycle**<br/>Power cycle (off then on)<br/>*Requires Authentication* | `curl -sk -X POST -u <admin-user-name>:<admin-password> -H "Content-Type: application/json" -d '{"ResetType": "PowerCycle"}' https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id>/Actions/ComputerSystem.Reset` | See [Perform Power Actions](#perform-power-actions) for details on all power operations | | |
| | **Get System Power State**<br/>Check current power state<br/>*Requires Authentication* | `curl -sk -u <admin-user-name>:<admin-password> https://<console_host_or_ip>:<console_port>/redfish/v1/Systems/<system-id> | jq .PowerState` | See [Get System Power State](#get-system-power-state) for details | |
|
|
||
| **Solution:** | ||
|
|
||
| - List all systems: `curl -u admin:password123 http://localhost:8181/redfish/v1/Systems` |
There was a problem hiding this comment.
The troubleshooting command here uses http:// while earlier sections assume HTTPS/TLS. For consistency (and to avoid readers testing the wrong scheme/port), update this to the same scheme used throughout the tutorial or explicitly call out when HTTP applies.
| - List all systems: `curl -u admin:password123 http://localhost:8181/redfish/v1/Systems` | |
| - List all systems: `curl -u admin:password123 https://localhost:8181/redfish/v1/Systems` |
|
|
||
| Install the following tools before running this tutorial: | ||
|
|
||
| 1. **curl** (for API calls) : Comes pre-installed on most of the OS'es, if not available install it from the official website(<https://curl.se/download.html>) or your OS package manager. |
There was a problem hiding this comment.
Spelling/grammar: “OS'es” should be “OSes” (or “operating systems”), and the sentence would read more cleanly without the apostrophe.
| 1. **curl** (for API calls) : Comes pre-installed on most of the OS'es, if not available install it from the official website(<https://curl.se/download.html>) or your OS package manager. | |
| 1. **curl** (for API calls) : Comes pre-installed on most operating systems; if not available, install it from the official website (<https://curl.se/download.html>) or your OS package manager. |
PR Checklist
What are you changing?
Added the redfish tutorial under the tutorial section. The redfish tutorial demonstrates how to set up, configure, and test the DMT Console Redfish API implementation.
Anything the reviewer should know when reviewing this PR?