incubator-deltacloud-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Lutterkort <lut...@redhat.com>
Subject Re: [PATCH] Fix typo in EC2 stop instance. No matter which instance you stopped you would always get the details of the first intance in the list returned.
Date Thu, 28 Jul 2011 20:30:44 GMT
On Thu, 2011-07-28 at 22:55 +0300, marios@redhat.com wrote:
> From: marios <marios@redhat.com>

ACK. This typo also affects reboot_instances.

> diff --git a/server/lib/deltacloud/drivers/ec2/ec2_driver.rb b/server/lib/deltacloud/drivers/ec2/ec2_driver.rb
> index 67a4de4..c73c4cd 100644
> --- a/server/lib/deltacloud/drivers/ec2/ec2_driver.rb
> +++ b/server/lib/deltacloud/drivers/ec2/ec2_driver.rb
> @@ -241,7 +241,7 @@ module Deltacloud
>          def destroy_instance(credentials, instance_id)
>            ec2 = new_client(credentials)
>            if ec2.terminate_instances([instance_id])
> -            instance(credentials, instance_id)
> +            instance(credentials, {:id=>instance_id})

You can leave the curly braces off, i.e. 'instance(credentials, :id =>
instance)' (that's what the rest of the code does)

David



Mime
View raw message