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 core] Allow creating 'sandbox' instances in GoGrid
Date Wed, 09 Feb 2011 23:27:32 GMT
On Wed, 2011-02-09 at 14:30 +0100, mfojtik@redhat.com wrote:
> From: Michal Fojtik <mfojtik@redhat.com>
> 
> ---
>  server/lib/deltacloud/base_driver/features.rb      |    7 +++++
>  .../lib/deltacloud/drivers/gogrid/gogrid_driver.rb |   24 ++++++++++---------
>  server/views/instances/new.html.haml               |    5 ++++
>  3 files changed, 25 insertions(+), 11 deletions(-)

ACK, with two comments: (1) how do we test this ? (2) minor nit below:

> diff --git a/server/lib/deltacloud/drivers/gogrid/gogrid_driver.rb b/server/lib/deltacloud/drivers/gogrid/gogrid_driver.rb
> index 909fade..e17cbe9 100644
> --- a/server/lib/deltacloud/drivers/gogrid/gogrid_driver.rb
> +++ b/server/lib/deltacloud/drivers/gogrid/gogrid_driver.rb

> @@ -425,7 +425,9 @@ class GogridDriver < Deltacloud::BaseDriver
>          opts[:hwp_memory] = (mem.to_i * 1024).to_s
>        end
>      end
> +
>      prof = InstanceProfile.new("server", opts)
> +    instance_name = "#{instance['name']} (sandbox)" if instance['isSandbox']

We shouldn't modify the name of the instance - if users are using these
names to identify instances, it would be very bad if we change them
behind their backs.

It's more work internally, but if we need to indicate that an instance
is sandboxed, we should do that with a separate element in the instance
XML.

David



Mime
View raw message