[Openstack] [Ceilometer/Heat] correct format of webhook for alarm-action
Steven Hardy
shardy at redhat.com
Wed Aug 27 10:30:41 UTC 2014
On Wed, Aug 27, 2014 at 10:04:53AM +0000, Duan, Li-Gong (Gary at HPServers-Core-OE-PSC) wrote:
> Hi Steve,
>
> Thanks for your reply.
> What I want to do is to define alarm action which will trigger heat to launch a stack, like executing "heat stack-create...".
> And by doing this, once the condition of the alarm is met(alarm in ceilometer is triggered), the heat stack will automatically created/launched, as defined in ceilometer action.
>
> If so, the alarms defined in ceilometer and actions(heat workflow) can be associated.
> My current issue is how to specify the webhook URL for launching a heat stack in ceilometer alarm action.
The only way to do this using only Heat and Ceilometer (as opposed to some
other service handling the alarm then calling Heat) is to use the
OS::Heat::AutoScalingGroup resource, which could be created with an initial
size of zero, then be triggered by ceilometer to scale up (which would be
basically the same as a stack-create on the nested template).
> If it is impossible, I have to specify alarm and policy in heat template.
I think that at the least you will need to define the ScalingPolicy
resource in the template, as that is the thing which provides the URL you
can pass to ceilometer.
There is no way to have ceilometer directly interact with heat to create
the stack, as previously mentioned, because it can't provide the necessary
data to create the stack (therefore you have to define it in the template
as described above).
Steve
More information about the Openstack
mailing list