diff options
author | huangtianhua <huangtianhua@huawei.com> | 2017-02-13 18:15:24 +0800 |
---|---|---|
committer | huangtianhua <huangtianhua@huawei.com> | 2017-02-14 10:41:04 +0800 |
commit | dedc3ac0af9797f8d7d8897380b0a457a226c00d (patch) | |
tree | 2e3a56808a949de1d54f40dcec484f791860e801 /heatclient/v1 | |
parent | 28cf99603a308640af604a83f3b3083ce3ad0d35 (diff) | |
download | python-heatclient-dedc3ac0af9797f8d7d8897380b0a457a226c00d.tar.gz |
Support openstack stack export
Heat supports exporting data of stack preparing
for abandon stack. This change supports
'openstack stack export' in client.
Change-Id: I5d3778f307d10174dbb738548282f7495bd9c825
Diffstat (limited to 'heatclient/v1')
-rw-r--r-- | heatclient/v1/stacks.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/heatclient/v1/stacks.py b/heatclient/v1/stacks.py index 2f02825..b6e6bf6 100644 --- a/heatclient/v1/stacks.py +++ b/heatclient/v1/stacks.py @@ -208,6 +208,13 @@ class StackManager(StackChildManager): body = utils.get_response_body(resp) return body + def export(self, stack_id): + """Export data of a stack.""" + stack_identifier = self._resolve_stack_id(stack_id) + resp = self.client.get('/stacks/%s/export' % stack_identifier) + body = utils.get_response_body(resp) + return body + def snapshot(self, stack_id, name=None): """Snapshot a stack.""" stack_identifier = self._resolve_stack_id(stack_id) |