2016-08-18 03:23:05 -04:00
|
|
|
.. -*- rst -*-
|
|
|
|
|
|
|
|
===============
|
|
|
|
Stack Snapshots
|
|
|
|
===============
|
|
|
|
|
2016-08-18 05:58:24 -04:00
|
|
|
Snapshot a stack
|
|
|
|
================
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
.. rest_method:: POST /v1/{tenant_id}/stacks/{stack_name}/{stack_id}/snapshots
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Takes a snapshot of all resources in a stack. All snapshots are deleted when
|
|
|
|
the stack is deleted.
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Response Codes
|
|
|
|
--------------
|
|
|
|
|
|
|
|
.. rest_status_code:: success status.yaml
|
|
|
|
|
|
|
|
- 200
|
|
|
|
|
|
|
|
.. rest_status_code:: error status.yaml
|
|
|
|
|
|
|
|
- 400
|
|
|
|
- 401
|
|
|
|
- 404
|
|
|
|
- 500
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Request Parameters
|
|
|
|
------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
|
|
|
- tenant_id: tenant_id
|
2016-08-18 05:58:24 -04:00
|
|
|
- stack_name: stack_name_url
|
|
|
|
- stack_id: stack_id_url
|
2016-08-19 03:46:09 -04:00
|
|
|
- name: snapshot_name
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Request Example
|
|
|
|
---------------
|
|
|
|
|
|
|
|
.. literalinclude:: samples/stack-snapshot-request.json
|
|
|
|
:language: javascript
|
|
|
|
|
|
|
|
Response Parameters
|
|
|
|
-------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
- X-Openstack-Request-Id: request_id
|
2016-08-18 03:23:05 -04:00
|
|
|
- creation_time: creation_time
|
2016-08-20 05:23:02 -04:00
|
|
|
- data: snapshot_data
|
2016-08-19 05:59:07 -04:00
|
|
|
- id: snapshot_id
|
2016-08-20 05:23:02 -04:00
|
|
|
- name: snapshot_name
|
|
|
|
- status: snapshot_status
|
|
|
|
- status_reason: snapshot_status_reason
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Response Example
|
|
|
|
----------------
|
|
|
|
|
|
|
|
.. literalinclude:: samples/stack-snapshot-response.json
|
|
|
|
:language: javascript
|
|
|
|
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
List snapshots
|
|
|
|
==============
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
.. rest_method:: GET /v1/{tenant_id}/stacks/{stack_name}/{stack_id}/snapshots
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Lists snapshots for a stack.
|
|
|
|
|
|
|
|
Response Codes
|
|
|
|
--------------
|
|
|
|
|
|
|
|
.. rest_status_code:: success status.yaml
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
- 200
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
.. rest_status_code:: error status.yaml
|
|
|
|
|
|
|
|
- 401
|
|
|
|
- 404
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Request Parameters
|
|
|
|
------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
|
|
|
- tenant_id: tenant_id
|
2016-08-18 05:58:24 -04:00
|
|
|
- stack_name: stack_name_url
|
|
|
|
- stack_id: stack_id_url
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Response Parameters
|
|
|
|
-------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
- X-Openstack-Request-Id: request_id
|
|
|
|
- snapshots: snapshots
|
2016-08-18 03:23:05 -04:00
|
|
|
- creation_time: creation_time
|
2016-08-20 05:23:02 -04:00
|
|
|
- data: snapshot_data
|
2016-08-19 05:59:07 -04:00
|
|
|
- id: snapshot_id
|
2016-08-20 05:23:02 -04:00
|
|
|
- name: snapshot_name
|
|
|
|
- status: snapshot_status
|
|
|
|
- status_reason: snapshot_status_reason
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Response Example
|
|
|
|
----------------
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
.. literalinclude:: samples/stack-snapshots-list-response.json
|
2016-08-18 03:23:05 -04:00
|
|
|
:language: javascript
|
|
|
|
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Show snapshot
|
|
|
|
=============
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
.. rest_method:: GET /v1/{tenant_id}/stacks/{stack_name}/{stack_id}/snapshots/{snapshot_id}
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Shows details for a snapshot.
|
|
|
|
|
|
|
|
Response Codes
|
|
|
|
--------------
|
|
|
|
|
|
|
|
.. rest_status_code:: success status.yaml
|
|
|
|
|
|
|
|
- 200
|
|
|
|
|
|
|
|
.. rest_status_code:: error status.yaml
|
|
|
|
|
|
|
|
- 401
|
|
|
|
- 404
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Request Parameters
|
|
|
|
------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
|
|
|
- tenant_id: tenant_id
|
2016-08-18 05:58:24 -04:00
|
|
|
- stack_name: stack_name_url
|
|
|
|
- stack_id: stack_id_url
|
2016-08-20 05:23:02 -04:00
|
|
|
- snapshot_id: snapshot_id_url
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Response Parameters
|
|
|
|
-------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
- X-Openstack-Request-Id: request_id
|
|
|
|
- snapshot: snapshot
|
2016-08-18 03:23:05 -04:00
|
|
|
- creation_time: creation_time
|
2016-08-20 05:23:02 -04:00
|
|
|
- data: snapshot_data
|
2016-08-19 05:59:07 -04:00
|
|
|
- id: snapshot_id
|
2016-08-20 05:23:02 -04:00
|
|
|
- name: snapshot_name
|
|
|
|
- status: snapshot_status
|
|
|
|
- status_reason: snapshot_status_reason
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Response Example
|
|
|
|
----------------
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
.. literalinclude:: samples/stack-snapshot-show-response.json
|
2016-08-18 03:23:05 -04:00
|
|
|
:language: javascript
|
|
|
|
|
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Restore snapshot
|
|
|
|
================
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
.. rest_method:: POST /v1/{tenant_id}/stacks/{stack_name}/{stack_id}/snapshots/{snapshot_id}/restore
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Restores a stack snapshot.
|
|
|
|
|
|
|
|
You can restore only active stacks from a snapshot. You must recreate deleted
|
|
|
|
stacks.
|
|
|
|
|
|
|
|
Response Codes
|
|
|
|
--------------
|
|
|
|
|
|
|
|
.. rest_status_code:: success status.yaml
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
- 202
|
|
|
|
|
|
|
|
.. rest_status_code:: error status.yaml
|
|
|
|
|
|
|
|
- 401
|
|
|
|
- 404
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Request Parameters
|
|
|
|
------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
|
|
|
- tenant_id: tenant_id
|
2016-08-18 05:58:24 -04:00
|
|
|
- stack_name: stack_name_url
|
|
|
|
- stack_id: stack_id_url
|
|
|
|
- snapshot_id: snapshot_id_url
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Response Parameters
|
|
|
|
-------------------
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
.. rest_parameters:: parameters.yaml
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
- X-Openstack-Request-Id: request_id
|
|
|
|
- code: restore_code
|
|
|
|
- message: restore_message
|
|
|
|
- title: restore_title
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
Response Example
|
|
|
|
----------------
|
2016-08-18 03:23:05 -04:00
|
|
|
|
2016-08-20 05:23:02 -04:00
|
|
|
.. literalinclude:: samples/stack-snapshot-restore-response.json
|
|
|
|
:language: javascript
|
|
|
|
|
|
|
|
|
|
|
|
Delete a snapshot
|
|
|
|
=================
|
|
|
|
|
|
|
|
.. rest_method:: DELETE /v1/{tenant_id}/stacks/{stack_name}/{stack_id}/snapshots/{snapshot_id}
|
|
|
|
|
|
|
|
Deletes a stack snapshot.
|
|
|
|
|
|
|
|
Response Codes
|
|
|
|
--------------
|
|
|
|
|
|
|
|
.. rest_status_code:: success status.yaml
|
|
|
|
|
|
|
|
- 204
|
|
|
|
|
|
|
|
.. rest_status_code:: error status.yaml
|
|
|
|
|
|
|
|
- 401
|
|
|
|
- 404
|
|
|
|
- 500
|
2016-08-18 03:23:05 -04:00
|
|
|
|
|
|
|
Request Parameters
|
|
|
|
------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
|
|
|
- tenant_id: tenant_id
|
2016-08-18 05:58:24 -04:00
|
|
|
- stack_name: stack_name_url
|
|
|
|
- stack_id: stack_id_url
|
|
|
|
- snapshot_id: snapshot_id_url
|
2016-08-20 05:23:02 -04:00
|
|
|
|
|
|
|
Response Parameters
|
|
|
|
-------------------
|
|
|
|
|
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
|
|
|
- X-Openstack-Request-Id: request_id
|
|
|
|
|
|
|
|
Response Example
|
|
|
|
----------------
|
|
|
|
|
|
|
|
The response to this API does not have a body.
|