vmm: http: Add a /api/v1/vm.snapshot endpoint

Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
This commit is contained in:
Samuel Ortiz
2019-11-24 19:37:08 +01:00
committed by Rob Bradford
parent cf8f8ce93a
commit 39d4f817f0
3 changed files with 71 additions and 4 deletions

View File

@@ -171,6 +171,24 @@ paths:
404:
description: The device could not be removed from the VM instance.
/vm.snapshot:
put:
summary: Returns a VM snapshot.
requestBody:
description: The snapshot configuration
content:
application/json:
schema:
$ref: '#/components/schemas/VmSnapshotConfig'
required: true
responses:
204:
description: The VM instance was successfully snapshotted.
404:
description: The VM instance could not be snapshotted because it is not created.
405:
description: The VM instance could not be snapshotted because it is not booted.
/vm.add-disk:
put:
summary: Add a new disk to the VM
@@ -542,3 +560,9 @@ components:
properties:
id:
type: string
VmSnapshotConfig:
type: object
properties:
destination_url:
type: string