summaryrefslogtreecommitdiffstats
path: root/tosca2heat/heat-translator/translator/hot/tosca/tosca_block_storage.py
diff options
context:
space:
mode:
authorshangxdy <shang.xiaodong@zte.com.cn>2017-02-26 16:22:30 +0800
committershangxdy <shang.xiaodong@zte.com.cn>2017-02-26 20:23:51 +0800
commitf7b240c6893a48d71da29974e54cb560b6575eb3 (patch)
tree3d3b8ea171640465cd30bd3d91a88a52cb4487b9 /tosca2heat/heat-translator/translator/hot/tosca/tosca_block_storage.py
parent406214e5ca40ad57a1c40e4a8454336f6a26cac2 (diff)
Sync heat-translator code
Sync heat-translator code from upstream JIRA:PARSER-119 Change-Id: I2287b78ad38bc54f7740fd1ee5f08989d5e680bf Signed-off-by: shangxdy <shang.xiaodong@zte.com.cn>
Diffstat (limited to 'tosca2heat/heat-translator/translator/hot/tosca/tosca_block_storage.py')
-rw-r--r--tosca2heat/heat-translator/translator/hot/tosca/tosca_block_storage.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/tosca2heat/heat-translator/translator/hot/tosca/tosca_block_storage.py b/tosca2heat/heat-translator/translator/hot/tosca/tosca_block_storage.py
index d4b2f44..27c1033 100644
--- a/tosca2heat/heat-translator/translator/hot/tosca/tosca_block_storage.py
+++ b/tosca2heat/heat-translator/translator/hot/tosca/tosca_block_storage.py
@@ -29,9 +29,10 @@ class ToscaBlockStorage(HotResource):
toscatype = 'tosca.nodes.BlockStorage'
- def __init__(self, nodetemplate):
+ def __init__(self, nodetemplate, csar_dir=None):
super(ToscaBlockStorage, self).__init__(nodetemplate,
- type='OS::Cinder::Volume')
+ type='OS::Cinder::Volume',
+ csar_dir=csar_dir)
pass
def handle_properties(self):
@@ -67,5 +68,5 @@ class ToscaBlockStorage(HotResource):
# attribute for the matching resource. Unless there is additional
# runtime support, this should be a one to one mapping.
if attribute == 'volume_id':
- attr['get_resource'] = args[0]
+ attr['get_resource'] = self.name
return attr