2015-11-26 15:12:47 |
Peter Razumovsky |
description |
I want private VolumeType resource with specified projects to access. I use next template:
heat_template_version: 2015-10-15
resources:
vt:
type: OS::Cinder::VolumeType
properties:
name: name
is_public: False
projects:
- admin
- demo
VolumeType fails during creating with next error: AttributeError: 'KeystoneClientV3' object has no attribute 'get_project_id'
Traceback:
2015-11-26 17:53:05.602 TRACE heat.engine.resource Traceback (most recent call last):
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 633, in _action_recorder
2015-11-26 17:53:05.602 TRACE heat.engine.resource yield
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 703, in _do_action
2015-11-26 17:53:05.602 TRACE heat.engine.resource yield self.action_handler_task(action, args=handler_args)
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/scheduler.py", line 295, in wrapper
2015-11-26 17:53:05.602 TRACE heat.engine.resource step = next(subtask)
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 674, in action_handler_task
2015-11-26 17:53:05.602 TRACE heat.engine.resource handler_data = handler(*args)
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resources/openstack/cinder/volume_type.py", line 99, in handle_create
2015-11-26 17:53:05.602 TRACE heat.engine.resource self._add_projects_access(self.properties[self.PROJECTS])
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resources/openstack/cinder/volume_type.py", line 83, in _add_projects_access
2015-11-26 17:53:05.602 TRACE heat.engine.resource project_id = self.keystone().get_project_id(project)
2015-11-26 17:53:05.602 TRACE heat.engine.resource AttributeError: 'KeystoneClientV3' object has no attribute 'get_project_id' |
I want private VolumeType resource with specified projects to access. I use next template:
heat_template_version: 2015-10-15
resources:
vt:
type: OS::Cinder::VolumeType
properties:
name: name
is_public: False
projects:
- admin
- demo
First case:
-----------
VolumeType fails during creating with next error: AttributeError: 'KeystoneClientV3' object has no attribute 'get_project_id'
Traceback:
2015-11-26 17:53:05.602 TRACE heat.engine.resource Traceback (most recent call last):
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 633, in _action_recorder
2015-11-26 17:53:05.602 TRACE heat.engine.resource yield
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 703, in _do_action
2015-11-26 17:53:05.602 TRACE heat.engine.resource yield self.action_handler_task(action, args=handler_args)
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/scheduler.py", line 295, in wrapper
2015-11-26 17:53:05.602 TRACE heat.engine.resource step = next(subtask)
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 674, in action_handler_task
2015-11-26 17:53:05.602 TRACE heat.engine.resource handler_data = handler(*args)
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resources/openstack/cinder/volume_type.py", line 99, in handle_create
2015-11-26 17:53:05.602 TRACE heat.engine.resource self._add_projects_access(self.properties[self.PROJECTS])
2015-11-26 17:53:05.602 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resources/openstack/cinder/volume_type.py", line 83, in _add_projects_access
2015-11-26 17:53:05.602 TRACE heat.engine.resource project_id = self.keystone().get_project_id(project)
2015-11-26 17:53:05.602 TRACE heat.engine.resource AttributeError: 'KeystoneClientV3' object has no attribute 'get_project_id'
Second case:
------------
Let take note, that some magic fixes first case issue. Now try to update volume type resource with another projects.
Update failed with error: TypeError: list indices must be integers, not str
Traceback:
2015-11-26 18:08:24.311 TRACE heat.engine.resource Traceback (most recent call last):
2015-11-26 18:08:24.311 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 633, in _action_recorder
2015-11-26 18:08:24.311 TRACE heat.engine.resource yield
2015-11-26 18:08:24.311 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 966, in update
2015-11-26 18:08:24.311 TRACE heat.engine.resource prop_diff])
2015-11-26 18:08:24.311 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/scheduler.py", line 295, in wrapper
2015-11-26 18:08:24.311 TRACE heat.engine.resource step = next(subtask)
2015-11-26 18:08:24.311 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resource.py", line 674, in action_handler_task
2015-11-26 18:08:24.311 TRACE heat.engine.resource handler_data = handler(*args)
2015-11-26 18:08:24.311 TRACE heat.engine.resource File "/opt/stack/heat/heat/engine/resources/openstack/cinder/volume_type.py", line 125, in handle_update
2015-11-26 18:08:24.311 TRACE heat.engine.resource self.resource_id)['volume_type_access']
2015-11-26 18:08:24.311 TRACE heat.engine.resource TypeError: list indices must be integers, not str |
|