/vpcs/{vpcs_id}/nio¶
Contents
POST /vpcs/{vpcs_id}/nio¶
ADD NIO to a VPCS
Parameters¶
- vpcs_id: Id of VPCS instance
Response status codes¶
- 201: Success of creation of NIO
- 409: Conflict
Input¶
Types¶
Ethernet¶
Generic Ethernet Network Input/Output
Name | Mandatory | Type | Description |
---|---|---|---|
ethernet_device | ✔ | string | Ethernet device name e.g. eth0 |
type | ✔ | enum | Possible values: nio_generic_ethernet |
LinuxEthernet¶
Linux Ethernet Network Input/Output
Name | Mandatory | Type | Description |
---|---|---|---|
ethernet_device | ✔ | string | Ethernet device name e.g. eth0 |
type | ✔ | enum | Possible values: nio_linux_ethernet |
TAP¶
TAP Network Input/Output
Name | Mandatory | Type | Description |
---|---|---|---|
tap_device | ✔ | string | TAP device name e.g. tap0 |
type | ✔ | enum | Possible values: nio_tap |
UDP¶
UDP Network Input/Output
Name | Mandatory | Type | Description |
---|---|---|---|
lport | ✔ | integer | Local port |
rhost | ✔ | string | Remote host |
rport | ✔ | integer | Remote port |
type | ✔ | enum | Possible values: nio_udp |
Sample session¶
POST /vpcs/{vpcs_id}/nio HTTP/1.1
{
"id": 42,
"nio": {
"local_file": "/tmp/test",
"remote_file": "/tmp/remote",
"type": "nio_unix"
},
"port": 0,
"port_id": 0
}
HTTP/1.1 200
CONNECTION: close
CONTENT-LENGTH: 48
DATE: Thu, 08 Jan 2015 09:33:10 GMT
SERVER: Python/3.4 aiohttp/0.13.1
X-ROUTE: /vpcs/{vpcs_id}/nio
{
"console": 4242,
"name": "PC 2",
"vpcs_id": 42
}