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] Reinstate the post /api call for changing provider in HTML UI /api when available (originally addressed in JIRA DTACLOUD-105 (EC2 Regions))
Date Thu, 24 May 2012 18:19:30 GMT
On Thu, 2012-05-24 at 18:48 +0300, marios@redhat.com wrote:
> From: marios <marios@redhat.com>
> 
> 
> Signed-off-by: marios <marios@redhat.com>

ACK; why can this only be used to set the provider ? Shouldn't we also
allow setting the driver through this call ?

Also: the commit message is too long (break it into multiple lines)

David

> ---
>  server/lib/deltacloud/server.rb |    9 +++++++++
>  1 files changed, 9 insertions(+), 0 deletions(-)
> 
> diff --git a/server/lib/deltacloud/server.rb b/server/lib/deltacloud/server.rb
> index fced64b..0df76e9 100644
> --- a/server/lib/deltacloud/server.rb
> +++ b/server/lib/deltacloud/server.rb
> @@ -53,6 +53,15 @@ module Deltacloud
>        end
>      end
>  
> +    post Deltacloud[:root_url] + '/?' do
> +      provider = params["provider"]
> +      if provider && provider != "default"
> +        redirect "#{Deltacloud[:root_url]}\;provider=#{params['provider']}", 301
> +      else
> +        redirect settings.root_url, 301
> +      end
> +    end
> +
>    end
>  end
>  




Mime
View raw message