def cloud_request(request, &block)
      Net::HTTP.start(@hostname, 443, use_ssl: true, read_timeout: 120) do |http|
        request['X-Auth-Token'] = @account.auth_token
        request['User-Agent'] = "raca 0.4.4 (http://rubygems.org/gems/raca)"
        response = http.request(request, &block)
        if response.is_a?(Net::HTTPSuccess)
          response
        else
          raise_on_error(request, response)
        end
      end
    end
def cloud_request(request, &block)
      Net::HTTP.start(@hostname, 443, use_ssl: true, read_timeout: 120) do |http|
        request['X-Auth-Token'] = @account.auth_token
        request['User-Agent'] = "raca 0.4.4 (http://rubygems.org/gems/raca)"
        response = http.request(request, &block)
        if response.is_a?(Net::HTTPSuccess)
          response
        else
          raise_on_error(request, response)
        end
      end
    end
perform an HTTP request to rackpsace.

 request is a Net::HTTP request object.
 This can be called with and without a block. Without a block, the response
 is returned as you'd expect

     response = http_client.cloud_request(request)

 With the block form, the response is yielded to the block:

     http_client.cloud_request(request) do |response|
       puts response
     end