Creating remote consoles for virtual machines
POST /servers/{server_id}/remote-consoles
Create a remote console for a virtual machine. The response contains a URL that can be used to open the console session. The URL includes a temporary console token that authorizes access to the console.
In Virtuozzo Infrastructure, the supported remote console protocol and type are:
protocol:vnctype:novnc
Source: https://docs.openstack.org/api-ref/compute/#create-console
Request
Parameters
| Name | In | Type | Description |
|---|---|---|---|
server_id
|
path | string | The UUID of the server. |
remote_console
|
body | object | The remote console object. |
protocol
|
body | string | The remote console protocol. The valid value is vnc. |
type
|
body | string | The remote console type. The valid value is novnc. |
Example
# curl -ks -H 'Content-Type: application/json' -H 'X-OpenStack-Nova-API-Version: 2.8' -H 'X-Auth-Token: gAAAAA<...>' -d '
{
"remote_console": {
"protocol": "vnc",
"type": "novnc"
}
}' https://<node_IP_addr>:8774/v2.1/servers/5a124ea0-36a0-49b8-9bd0-e937d958ca8f/remote-consoles
Response
Parameters
| Name | In | Type | Description |
|---|---|---|---|
remote_console
|
body | object | The remote console object. |
protocol
|
body | string | The remote console protocol. The valid value is vnc. |
type
|
body | string | The remote console type. The valid value is novnc. |
url
|
body | string | The URL used to open the console. |
Status codes
Success
| Code | Reason |
|---|---|
200 - OK
|
Request was successful. |
Error
| Code | Reason |
|---|---|
400 - Bad Request
|
Some content in the request was invalid. |
401 - Unauthorized
|
User must authenticate before making a request. |
403 - Forbidden
|
Policy does not allow current user to do this operation. |
404 - Not Found
|
The requested resource could not be found. |
409 - Conflict
|
This operation conflicted with another operation on this resource. |
501 - Not Implemented
|
The server either does not recognize the request method, or it lacks the ability to fulfill the request. |
Example
{
"remote_console": {
"protocol": "vnc",
"type": "novnc",
"url": "https://10.136.18.152:6080/vnc_auto.html?path=websockify%3Ftoken%3D6587c1f6-3ba4-4c6d-b82d-a0bf5a8cf81e&token=6587c1f6-3ba4-4c6d-b82d-a0bf5a8cf81e"
}
}