This switches the volume creation to be done using Heat and
attached via Nova instead of letting Nova create it right away.
The reason behind this is that it will probably be much cleaner
for clean-up and Heat is much more 'patient' in order to get
the resource created.
Change-Id: Ifc70acb967a8a2f4007aa3b020232258b4032aec
Signed-off-by: Mohammed Naser <mnaser@vexxhost.com>
description: VM Image to spin up
resources:
description: VM Image to spin up
resources:
+ volume:
+ type: "OS::Cinder::Volume"
+ properties:
+ image: {get_param: vm_image}
+ size: 40
instance:
type: "OS::Nova::Server"
properties:
flavor: {get_param: vm_flavor}
block_device_mapping_v2:
instance:
type: "OS::Nova::Server"
properties:
flavor: {get_param: vm_flavor}
block_device_mapping_v2:
- - image: {get_param: vm_image}
- delete_on_termination: true
- volume_size: 40
+ - volume_id: {get_resource: volume}
name:
str_replace:
template: SILO-JOB_NAME-GROUP-VM_TYPE-INDEX
name:
str_replace:
template: SILO-JOB_NAME-GROUP-VM_TYPE-INDEX