rapi: Add resource for modifying node
[ganeti-local] / doc / rapi.rst
index 84281f2..238b849 100644 (file)
@@ -53,8 +53,8 @@ Example::
 
 
 .. [#pwhash] Using the MD5 hash of username, realm and password is
-   described in :rfc:`2617` ("HTTP Authentication"), sections 3.2.2.2 and
-   3.3. The reason for using it over another algorithm is forward
+   described in :rfc:`2617` ("HTTP Authentication"), sections 3.2.2.2
+   and 3.3. The reason for using it over another algorithm is forward
    compatibility. If ``ganeti-rapi`` were to implement HTTP Digest
    authentication in the future, the same hash could be used.
    In the current version ``ganeti-rapi``'s realm, ``Ganeti Remote
@@ -477,6 +477,10 @@ Body parameters:
 .. opcode_params:: OP_GROUP_SET_PARAMS
    :exclude: group_name
 
+Job result:
+
+.. opcode_result:: OP_GROUP_SET_PARAMS
+
 
 ``/2/groups/[group_name]/rename``
 +++++++++++++++++++++++++++++++++
@@ -495,6 +499,10 @@ Body parameters:
 .. opcode_params:: OP_GROUP_RENAME
    :exclude: group_name
 
+Job result:
+
+.. opcode_result:: OP_GROUP_RENAME
+
 
 ``/2/groups/[group_name]/assign-nodes``
 +++++++++++++++++++++++++++++++++++++++
@@ -640,6 +648,10 @@ Earlier versions used parameters named ``name`` and ``os``. These have
 been replaced by ``instance_name`` and ``os_type`` to match the
 underlying opcode. The old names can still be used.
 
+Job result:
+
+.. opcode_result:: OP_INSTANCE_CREATE
+
 
 ``/2/instances/[instance_name]``
 ++++++++++++++++++++++++++++++++
@@ -919,6 +931,10 @@ Body parameters:
 .. opcode_params:: OP_INSTANCE_RENAME
    :exclude: instance_name
 
+Job result:
+
+.. opcode_result:: OP_INSTANCE_RENAME
+
 
 ``/2/instances/[instance_name]/modify``
 ++++++++++++++++++++++++++++++++++++++++
@@ -937,6 +953,10 @@ Body parameters:
 .. opcode_params:: OP_INSTANCE_SET_PARAMS
    :exclude: instance_name
 
+Job result:
+
+.. opcode_result:: OP_INSTANCE_SET_PARAMS
+
 
 ``/2/instances/[instance_name]/console``
 ++++++++++++++++++++++++++++++++++++++++
@@ -957,20 +977,23 @@ console. Contained keys:
      constants.CONS_MESSAGE,
      constants.CONS_SSH,
      constants.CONS_VNC,
+     constants.CONS_SPICE,
      ])
 
 ``instance``
   Instance name.
 ``kind``
   Console type, one of :pyeval:`constants.CONS_SSH`,
-  :pyeval:`constants.CONS_VNC` or :pyeval:`constants.CONS_MESSAGE`.
+  :pyeval:`constants.CONS_VNC`, :pyeval:`constants.CONS_SPICE`
+  or :pyeval:`constants.CONS_MESSAGE`.
 ``message``
   Message to display (:pyeval:`constants.CONS_MESSAGE` type only).
 ``host``
-  Host to connect to (:pyeval:`constants.CONS_SSH` and
-  :pyeval:`constants.CONS_VNC` only).
+  Host to connect to (:pyeval:`constants.CONS_SSH`,
+  :pyeval:`constants.CONS_VNC` or :pyeval:`constants.CONS_SPICE` only).
 ``port``
-  TCP port to connect to (:pyeval:`constants.CONS_VNC` only).
+  TCP port to connect to (:pyeval:`constants.CONS_VNC` or
+  :pyeval:`constants.CONS_SPICE` only).
 ``user``
   Username to use (:pyeval:`constants.CONS_SSH` only).
 ``command``
@@ -1240,6 +1263,10 @@ Up to and including Ganeti 2.4 query arguments were used. Those are no
 longer supported. The new request can be detected by the presence of the
 :pyeval:`rlib2._NODE_EVAC_RES1` feature string.
 
+Job result:
+
+.. opcode_result:: OP_NODE_EVACUATE
+
 
 ``/2/nodes/[node_name]/migrate``
 +++++++++++++++++++++++++++++++++
@@ -1299,6 +1326,28 @@ be a job id.
 
 It supports the bool ``force`` argument.
 
+
+``/2/nodes/[node_name]/modify``
++++++++++++++++++++++++++++++++++
+
+Modifies the parameters of a node. Supports the following commands:
+``POST``.
+
+``POST``
+~~~~~~~
+
+Returns a job ID.
+
+Body parameters:
+
+.. opcode_params:: OP_NODE_SET_PARAMS
+   :exclude: node_name
+
+Job result:
+
+.. opcode_result:: OP_NODE_SET_PARAMS
+
+
 ``/2/nodes/[node_name]/storage``
 ++++++++++++++++++++++++++++++++