You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@deltacloud.apache.org by lu...@redhat.com on 2011/09/29 00:28:33 UTC

[PATCH 3/6] client: base64 encode passed-in user data

From: David Lutterkort <lu...@redhat.com>


Signed-off-by: David Lutterkort <lu...@redhat.com>
---
 client/lib/deltacloud.rb |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/client/lib/deltacloud.rb b/client/lib/deltacloud.rb
index 91e4f5f..fcf6e49 100644
--- a/client/lib/deltacloud.rb
+++ b/client/lib/deltacloud.rb
@@ -290,6 +290,7 @@ module DeltaCloud
 
         params[:realm_id] ||= params[:realm] if params[:realm]
         params[:keyname] ||= params[:key_name] if params[:key_name]
+        params[:user_data] = Base64::encode64(params[:user_data]) if params[:user_data]
 
         if params[:hardware_profile] and params[:hardware_profile].class.eql?(Hash)
           params[:hardware_profile].each do |k,v|
-- 
1.7.6


Re: [PATCH 3/6] client: base64 encode passed-in user data

Posted by Michal Fojtik <mf...@redhat.com>.
On Sep 29, 2011, at 12:28 AM, lutter@redhat.com wrote:

ACK to whole set :-)

  -- Michal

> From: David Lutterkort <lu...@redhat.com>
> 
> 
> Signed-off-by: David Lutterkort <lu...@redhat.com>
> ---
> client/lib/deltacloud.rb |    1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/client/lib/deltacloud.rb b/client/lib/deltacloud.rb
> index 91e4f5f..fcf6e49 100644
> --- a/client/lib/deltacloud.rb
> +++ b/client/lib/deltacloud.rb
> @@ -290,6 +290,7 @@ module DeltaCloud
> 
>         params[:realm_id] ||= params[:realm] if params[:realm]
>         params[:keyname] ||= params[:key_name] if params[:key_name]
> +        params[:user_data] = Base64::encode64(params[:user_data]) if params[:user_data]
> 
>         if params[:hardware_profile] and params[:hardware_profile].class.eql?(Hash)
>           params[:hardware_profile].each do |k,v|
> -- 
> 1.7.6
> 

------------------------------------------------------
Michal Fojtik, mfojtik@redhat.com
Deltacloud API: http://deltacloud.org