gns3-server/docs/api/v2/controller/vm/projectsprojectidvms.rst

57 lines
3.9 KiB
ReStructuredText
Raw Normal View History

/v2/projects/{project_id}/vms
2016-03-11 16:21:21 +02:00
------------------------------------------------------------------------------------------------------------------------------------------
.. contents::
POST /v2/projects/**{project_id}**/vms
2016-03-11 16:21:21 +02:00
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Create a new VM instance
Parameters
**********
- **project_id**: UUID for the project
Response status codes
**********************
- **400**: Invalid request
- **201**: Instance created
Input
*******
.. raw:: html
<table>
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
2016-04-18 17:49:36 +03:00
<tr><td>compute_id</td> <td>&#10004;</td> <td>string</td> <td>Hypervisor identifier</td> </tr>
2016-03-11 16:21:21 +02:00
<tr><td>console</td> <td> </td> <td>['integer', 'null']</td> <td>Console TCP port</td> </tr>
<tr><td>console_type</td> <td> </td> <td>enum</td> <td>Possible values: serial, vnc, telnet</td> </tr>
<tr><td>name</td> <td>&#10004;</td> <td>string</td> <td>VM name</td> </tr>
<tr><td>project_id</td> <td> </td> <td>string</td> <td>Project identifier</td> </tr>
<tr><td>properties</td> <td> </td> <td>object</td> <td>Properties specific to an emulator</td> </tr>
<tr><td>vm_id</td> <td> </td> <td>string</td> <td>VM identifier</td> </tr>
<tr><td>vm_type</td> <td>&#10004;</td> <td>enum</td> <td>Possible values: docker, dynamips, vpcs, virtualbox, vmware, iou</td> </tr>
</table>
Output
*******
.. raw:: html
<table>
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
2016-04-18 17:49:36 +03:00
<tr><td>compute_id</td> <td>&#10004;</td> <td>string</td> <td>Hypervisor identifier</td> </tr>
2016-03-11 16:21:21 +02:00
<tr><td>console</td> <td> </td> <td>['integer', 'null']</td> <td>Console TCP port</td> </tr>
<tr><td>console_type</td> <td> </td> <td>enum</td> <td>Possible values: serial, vnc, telnet</td> </tr>
<tr><td>name</td> <td>&#10004;</td> <td>string</td> <td>VM name</td> </tr>
<tr><td>project_id</td> <td> </td> <td>string</td> <td>Project identifier</td> </tr>
<tr><td>properties</td> <td> </td> <td>object</td> <td>Properties specific to an emulator</td> </tr>
<tr><td>vm_id</td> <td> </td> <td>string</td> <td>VM identifier</td> </tr>
<tr><td>vm_type</td> <td>&#10004;</td> <td>enum</td> <td>Possible values: docker, dynamips, vpcs, virtualbox, vmware, iou</td> </tr>
</table>
2016-03-11 18:20:09 +02:00
Sample session
***************
.. literalinclude:: ../../../examples/controller_post_projectsprojectidvms.txt