2010-10-28 20:50:46 -04:00
|
|
|
module Fog
|
|
|
|
module AWS
|
|
|
|
class IAM
|
|
|
|
class Real
|
|
|
|
|
|
|
|
require 'fog/aws/parsers/iam/create_group'
|
|
|
|
|
|
|
|
# Create a new group
|
|
|
|
#
|
|
|
|
# ==== Parameters
|
2010-11-09 20:47:35 -05:00
|
|
|
# * group_name<~String>: name of the group to create (do not include path)
|
|
|
|
# * path<~String>: optional path to group, defaults to '/'
|
2010-10-28 20:50:46 -04:00
|
|
|
#
|
|
|
|
# ==== Returns
|
|
|
|
# * response<~Excon::Response>:
|
|
|
|
# * body<~Hash>:
|
|
|
|
# * 'Group'<~Hash>:
|
|
|
|
# * Arn<~String> -
|
|
|
|
# * GroupId<~String> -
|
|
|
|
# * GroupName<~String> -
|
|
|
|
# * Path<~String> -
|
|
|
|
# * 'RequestId'<~String> - Id of the request
|
2010-11-09 20:47:35 -05:00
|
|
|
#
|
|
|
|
# ==== See Also
|
|
|
|
# http://docs.amazonwebservices.com/IAM/latest/APIReference/API_CreateGroup.html
|
|
|
|
#
|
2010-10-28 20:50:46 -04:00
|
|
|
def create_group(group_name, path = '/')
|
|
|
|
request(
|
|
|
|
'Action' => 'CreateGroup',
|
|
|
|
'GroupName' => group_name,
|
|
|
|
'Path' => path,
|
2010-11-09 20:47:35 -05:00
|
|
|
:parser => Fog::Parsers::AWS::IAM::CreateGroup.new
|
2010-10-28 20:50:46 -04:00
|
|
|
)
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|