diff --git a/src/vmm_mad/remotes/ec2/ec2_driver.rb b/src/vmm_mad/remotes/ec2/ec2_driver.rb index 7223012df0..0a66997e38 100755 --- a/src/vmm_mad/remotes/ec2/ec2_driver.rb +++ b/src/vmm_mad/remotes/ec2/ec2_driver.rb @@ -325,20 +325,6 @@ class EC2Driver sleep 2 end - tags = generate_options(:tags, ec2_info)[:tags] || {} - - tags['ONE_ID'] = id - - tag_array = [] - tags.each{ |key,value| - tag_array << { - :key => key, - :value => value - } - } - - instance.create_tags(:tags => tag_array) - elastic_ip = ec2_value(ec2_info, 'ELASTICIP') if elastic_ip @@ -360,6 +346,20 @@ class EC2Driver wait_state('running', instance.id) + tags = generate_options(:tags, ec2_info)[:tags] || {} + + tags['ONE_ID'] = id + + tag_array = [] + tags.each{ |key,value| + tag_array << { + :key => key, + :value => value + } + } + + instance.create_tags(:tags => tag_array) + puts(instance.id) else restore(deploy_id)