[chef] Re: Re: Re: call the aws ec2 REST API to create the security group or create the instance


Chronological Thread 
  • From: Erik Hollensbe < >
  • To:
  • Subject: [chef] Re: Re: Re: call the aws ec2 REST API to create the security group or create the instance
  • Date: Fri, 21 Dec 2012 14:16:16 -0800

If you do end up rolling your own, ruby's URI escaping mechanisms don't match what amazon wants (amazon wants one RFC, ruby provides another).

This took a while to sort out when I needed to hand roll some stuff in the past. :) Luckily aws-sdk does damn near everything you need to do with AWS and ruby these days.

-- 
Erik Hollensbe
Sent with Sparrow

On Friday, December 21, 2012 at 2:04 PM, Daniel Condomitti wrote:

Yeah, if you're not going to use the gems you'll need to structure the request correctly, generate the HMAC signature (of the payload and HTTP headers along with a timestamp) and sign the requests. This is done by including an authorization header or signature query string param of the previously computed signature. 

It's not difficult but definitely not worth dealing with the APIs directly over using the available gems. Read this to learn how to sign the requests: http://s3.amazonaws.com/doc/s3-developer-guide/RESTAuthentication.html

On Friday, December 21, 2012 at 4:56 PM, Mike wrote:

Ganesan,

You are expected to typically leverage the AWS EC2 API via tools in some way.

There are very specific, widely used tools here:

There's also abstraction libraries like fog - http://fog.io/ - that
can do a lot of these actions.

If you want to write your own, then by all means, but I definitely
think that is beyond the scope of the Chef lists.

Best,
-M





Archive powered by MHonArc 2.6.16.

§