[Openstack] [Tuskar-ui] Problem when Tuskar-ui deploy a plan

严超 yanchao727 at gmail.com
Mon Sep 15 06:28:59 UTC 2014


Hi, everyone:
        I'm trying to use Tuskar-ui to deploy an overcloud baremetal. But
when I comfirmed and click the "deploy" buttom, it always got the following
error. I really appreciate any help for this.

DEBUG:tuskar_ui.api.tuskar:tuskarclient connection created using token
"c814a946a77c11be3f1fcd79d0a9bcd5" and url "http://192.0.2.19:8585/"
DEBUG:tuskarclient.common.http:curl -i -X GET -H 'X-Auth-Token:
c814a946a77c11be3f1fcd79d0a9bcd5' -H 'Content-Type: application/json' -H
'Accept: application/json' -H 'User-Agent: python-tuskarclient'
http://192.0.2.19:8585//v2/plans/8edb6d86-04d2-4792-906e-9677655477b8/templates
DEBUG:tuskarclient.common.http:
HTTP/1.0 200 OK
date: Mon, 15 Sep 2014 06:15:14 GMT
content-length: 2014
content-type: application/json; charset=UTF-8
server: WSGIServer/0.1 Python/2.7.6

{"plan.yaml": "description: overcloud\nheat_template_version:
'2014-10-16'\noutputs:\n  controller-1::ip:\n    value:\n
get_attr:\n      - controller-1-resource-servers\n      -
ip\nparameters:\n  controller-1::count:\n    constraints:\n    -
range:\n        min: '1'\n    type: number\n  controller-1::image_id:\n
description: ID of the image to use\n    type: string\n
controller-1::instance_type:\n    constraints:\n    -
allowed_values:\n      - baremetal\n      - m1.large\n      description:
instance_type must be one of baremetal, m1.large\n    default:
baremetal\n    description: Instance type\n    type: string\nresources:\n
controller-1-resource-servers:\n    properties:\n      count:\n
get_param:\n        - controller-1::count\n      resource_def:\n
properties:\n          image_id:\n            get_param:\n            -
controller-1::image_id\n          instance_type:\n
get_param:\n            - controller-1::instance_type\n        type:
Tuskar::controller-1\n    type: OS::Heat::ResourceGroup\n",
"environment.yaml": "parameters:\n  controller-1::count: '1'\n
controller-1::image_id: ''\n  controller-1::instance_type:
baremetal\nresource_registry:\n  Tuskar::controller-1:
provider-controller-1.yaml\n", "provider-controller-1.yaml": "description:
'Creates a controller server\n\n  '\nheat_template_version:
2013-05-23\noutputs:\n  ip:\n    description: IP of the created
instance\n    value:\n      get_attr:\n      - controller_server\n      -
first_address\nparameters:\n  image_id:\n    description: ID of the image
to use\n    type: string\n  instance_type:\n    constraints:\n    -
allowed_values:\n      - baremetal\n      - m1.large\n      description:
instance_type must be one of baremetal, m1.large\n    default:
baremetal\n    description: Instance type\n    type: string\nresources:\n
controller_server:\n    properties:\n      flavor:\n        get_param:
instance_type\n      image:\n        get_param: image_id\n    type:
OS::Nova::Server\n"}

ERROR:tuskar_ui.infrastructure.overview.forms:roles
Traceback (most recent call last):
  File "/home/stack/tuskar-ui/tuskar_ui/infrastructure/overview/forms.py",
line 90, in handle
    plan.master_template,
  File "/home/stack/horizon/openstack_dashboard/api/base.py", line 81, in
__getattribute__
    return object.__getattribute__(self, attr)
  File "/home/stack/tuskar-ui/tuskar_ui/cached_property.py", line 60, in
__get__
    res = instance.__dict__[self.func.__name__] = self.func(instance)
  File "/home/stack/tuskar-ui/tuskar_ui/api/tuskar.py", line 174, in
master_template
    return self.templates.get(MASTER_TEMPLATE_NAME, '')
  File "/home/stack/horizon/openstack_dashboard/api/base.py", line 81, in
__getattribute__
    return object.__getattribute__(self, attr)
  File "/home/stack/tuskar-ui/tuskar_ui/cached_property.py", line 60, in
__get__
    res = instance.__dict__[self.func.__name__] = self.func(instance)
  File "/home/stack/tuskar-ui/tuskar_ui/api/tuskar.py", line 170, in
templates
    return tuskarclient(self._request).plans.templates(self.uuid)
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/v2/plans.py",
line 159, in templates
    return self._get(self._templates_path(plan_uuid)).to_dict()
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/common/base.py",
line 78, in _get
    return self._list(url, **kwargs)[0]
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/common/base.py",
line 98, in _list
    return [obj_class(self, res, loaded=True) for res in data if res]
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/v2/plans.py",
line 28, in __init__
    self.roles = [roles.Role(None, role) for role in self.roles]
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/openstack/common/apiclient/base.py",
line 464, in __getattr__
    raise AttributeError(k)
AttributeError: roles
Internal Server Error: /infrastructure/deploy-confirmation
Traceback (most recent call last):
  File
"/home/stack/horizon/.venv/local/lib/python2.7/site-packages/django/core/handlers/base.py",
line 112, in get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/home/stack/horizon/horizon/decorators.py", line 36, in dec
    return view_func(request, *args, **kwargs)
  File "/home/stack/horizon/horizon/decorators.py", line 84, in dec
    return view_func(request, *args, **kwargs)
  File "/home/stack/horizon/horizon/decorators.py", line 52, in dec
    return view_func(request, *args, **kwargs)
  File "/home/stack/horizon/horizon/decorators.py", line 36, in dec
    return view_func(request, *args, **kwargs)
  File
"/home/stack/horizon/.venv/local/lib/python2.7/site-packages/django/views/generic/base.py",
line 69, in view
    return self.dispatch(request, *args, **kwargs)
  File
"/home/stack/horizon/.venv/local/lib/python2.7/site-packages/django/views/generic/base.py",
line 87, in dispatch
    return handler(request, *args, **kwargs)
  File
"/home/stack/horizon/.venv/local/lib/python2.7/site-packages/django/views/generic/edit.py",
line 171, in post
    return self.form_valid(form)
  File "/home/stack/horizon/horizon/forms/views.py", line 87, in form_valid
    exceptions.handle(self.request)
  File "/home/stack/horizon/horizon/exceptions.py", line 334, in handle
    six.reraise(exc_type, exc_value, exc_traceback)
  File "/home/stack/horizon/horizon/forms/views.py", line 84, in form_valid
    handled = form.handle(self.request, form.cleaned_data)
  File "/home/stack/tuskar-ui/tuskar_ui/infrastructure/overview/forms.py",
line 96, in handle
    _("Unable to deploy overcloud."))
  File "/home/stack/horizon/horizon/exceptions.py", line 334, in handle
    six.reraise(exc_type, exc_value, exc_traceback)
  File "/home/stack/tuskar-ui/tuskar_ui/infrastructure/overview/forms.py",
line 90, in handle
    plan.master_template,
  File "/home/stack/horizon/openstack_dashboard/api/base.py", line 81, in
__getattribute__
    return object.__getattribute__(self, attr)
  File "/home/stack/tuskar-ui/tuskar_ui/cached_property.py", line 60, in
__get__
    res = instance.__dict__[self.func.__name__] = self.func(instance)
  File "/home/stack/tuskar-ui/tuskar_ui/api/tuskar.py", line 174, in
master_template
    return self.templates.get(MASTER_TEMPLATE_NAME, '')
  File "/home/stack/horizon/openstack_dashboard/api/base.py", line 81, in
__getattribute__
    return object.__getattribute__(self, attr)
  File "/home/stack/tuskar-ui/tuskar_ui/cached_property.py", line 60, in
__get__
    res = instance.__dict__[self.func.__name__] = self.func(instance)
  File "/home/stack/tuskar-ui/tuskar_ui/api/tuskar.py", line 170, in
templates
    return tuskarclient(self._request).plans.templates(self.uuid)
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/v2/plans.py",
line 159, in templates
    return self._get(self._templates_path(plan_uuid)).to_dict()
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/common/base.py",
line 78, in _get
    return self._list(url, **kwargs)[0]
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/common/base.py",
line 98, in _list
    return [obj_class(self, res, loaded=True) for res in data if res]
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/v2/plans.py",
line 28, in __init__
    self.roles = [roles.Role(None, role) for role in self.roles]
  File
"/home/stack/horizon/.venv/src/python-tuskarclient/tuskarclient/openstack/common/apiclient/base.py",
line 464, in __getattr__
    raise AttributeError(k)
AttributeError: roles
[15/Sep/2014 06:15:14] "POST /infrastructure/deploy-confirmation HTTP/1.1"
500 28635
[image: 内嵌图片 2]

*Best Regards!*


*Chao Yan--------------**My twitter:Andy Yan @yanchao727
<https://twitter.com/yanchao727>*


*My Weibo:http://weibo.com/herewearenow
<http://weibo.com/herewearenow>--------------*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack/attachments/20140915/54d7b76c/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 2014-09-15 14:28:25的屏幕截图.png
Type: image/png
Size: 87597 bytes
Desc: not available
URL: <http://lists.openstack.org/pipermail/openstack/attachments/20140915/54d7b76c/attachment.png>


More information about the Openstack mailing list