Created
April 3, 2011 04:30
-
-
Save hh/900181 to your computer and use it in GitHub Desktop.
Attempting to follow http://blog.zerosum.org/2011/03/02/better-aws-access-control-with-iam-and-fog.html fails when trying to run iam.create_access_key
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% rvm use 1.9.2@fog --create | |
Using /Users/codecafe/.rvm/gems/ruby-1.9.2-p180 with gemset fog | |
% gem install fog | |
% gem list | |
*** LOCAL GEMS *** | |
builder (3.0.0) | |
excon (0.6.0) | |
fog (0.7.1) | |
formatador (0.1.2) | |
json (1.5.1) | |
mime-types (1.16) | |
net-ssh (2.1.3) | |
nokogiri (1.4.4) | |
rake (0.8.7) | |
ruby-hmac (0.4.0) | |
% irb | |
require 'fog' | |
new_username = 'myusername' | |
bucket_name = 'mybucket' | |
aws_credentials = { | |
:aws_access_key_id => 'XXXCXCATATTETT', | |
:aws_secret_access_key => 'loremipsumgratisforumquorum', | |
} | |
iam = Fog::AWS::IAM.new(aws_credentials) | |
user_response = iam.create_user(new_username) | |
key_response = iam.create_access_key('UserName' => new_username) | |
Excon::Errors::SocketError: wrong number of arguments (3 for 1) | |
from /Users/codecafe/.rvm/gems/ruby-1.9.2-p180@fog/gems/fog-0.7.1/lib/fog/core/connection.rb:16:in `block in request' | |
from /Users/codecafe/.rvm/gems/ruby-1.9.2-p180@fog/gems/excon-0.6.0/lib/excon/response.rb:47:in `parse' | |
from /Users/codecafe/.rvm/gems/ruby-1.9.2-p180@fog/gems/excon-0.6.0/lib/excon/connection.rb:140:in `request' | |
from /Users/codecafe/.rvm/gems/ruby-1.9.2-p180@fog/gems/fog-0.7.1/lib/fog/core/connection.rb:20:in `request' | |
from /Users/codecafe/.rvm/gems/ruby-1.9.2-p180@fog/gems/fog-0.7.1/lib/fog/aws/iam.rb:106:in `request' | |
from /Users/codecafe/.rvm/gems/ruby-1.9.2-p180@fog/gems/fog-0.7.1/lib/fog/aws/requests/iam/create_access_key.rb:31:in `create_access_key' | |
from (irb):12 | |
from /Users/codecafe/.rvm/rubies/ruby-1.9.2-p180/bin/irb:16:in `<main>' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello, I don't know the context of this gist, probably during an IRC chat. However, I am writing a custom storage provider for Fog and I also bump into this exception. Do you have any hint what the problem is here? Any info you can pass on to work around this would be most welcome!
Ringo