TL;DR Is there any reason why stack-update doesn¹t reuse the existing
parameters when I extend my stack definition with a resource that uses
them?

I have created a stack from the hello_world.yaml template
(https://github.com/openstack/heat-templates/blob/master/hot/hello_world.ya
ml)
It has the following parameters keyname, image, flavor, admin_pass,
db_port.

heat stack-create hello_world -P
"key_name=test_keypair;image=test_image_cirros;flavor=m1.test_heat;admin_pa
ss=Openst1" -f hello_world.yaml

Then I have added one more nova server resource with new name(server1),
rest all the details are untouched.

I get the following when I use this new template without mentioning any of
the parameter value.

heat --debug stack-update hello_world -f hello_world_modified.yaml

On debugging it throws the below exception.
The resource was found
athttp://localhost:8004/v1/7faee9dd37074d3e8896957dc4a52e22/stacks/hello_wo
rld/85a0bc2c-1a20-45c4-a8a9-7be727db6a6d; you should be redirected
automatically.
DEBUG (session) RESP: [400] CaseInsensitiveDict({'date': 'Wed, 24 Sep 2014
10:08:08 GMT', 'content-length': '961', 'content-type': 'application/json;
charset=UTF-8'})
RESP BODY: {"explanation": "The server could not comply with the request
since it is either malformed or otherwise incorrect.", "code": 400,
"error": {"message": "The Parameter (admin_pass) was not provided.",
"traceback": "Traceback (most recent call last):\n\n  File
\"/opt/stack/heat/heat/engine/service.py\", line 63, in wrapped\n
return func(self, ctx, *args, **kwargs)\n\n  File
\"/opt/stack/heat/heat/engine/service.py\", line 576, in update_stack\n
env, **common_params)\n\n  File \"/opt/stack/heat/heat/engine/parser.py\",
line 109, in __init__\n    context=context)\n\n  File
\"/opt/stack/heat/heat/engine/parameters.py\", line 403, in validate\n
param.validate(validate_value, context)\n\n  File
\"/opt/stack/heat/heat/engine/parameters.py\", line 215, in validate\n
raise 
exception.UserParameterMissing(key=self.name)\n\nUserParameterMissing: The
Parameter (admin_pass) was not provided.\n", "type":
"UserParameterMissing"}, "title": "Bad Request"}

When I mention all the parameters then it updates the stack properly

heat --debug stack-update hello_world -P
"key_name=test_keypair;image=test_image_cirros;flavor=m1.test_heat;admin_pa
ss=Openst1" -f hello_world_modified.yaml

Any reason why I can¹t reuse the existing parameters during the
stack-update if I don¹t  want to specify them again?

-
Dimitri



_______________________________________________
OpenStack-dev mailing list
OpenStack-dev@lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

Reply via email to