1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00
fog--fog/lib/fog/aws/requests/redshift/create_cluster_security_group.rb

43 lines
1.5 KiB
Ruby
Raw Normal View History

module Fog
module AWS
class Redshift
class Real
require 'fog/aws/parsers/redshift/create_cluster_security_group'
# ==== Parameters
2014-02-19 12:30:59 +00:00
#
# @param [Hash] options
2014-02-19 12:30:59 +00:00
# * :cluster_security_group_name - (String)
# The name of a cluster security group for which you are requesting details. You
# can specify either the Marker parameter or a ClusterSecurityGroupName parameter,
# but not both. Example: securitygroup1
# * :description - required - (String)
2014-02-19 12:30:59 +00:00
# A description for the security group.
#
# ==== See Also
2014-02-19 12:30:59 +00:00
# http://docs.aws.amazon.com/redshift/latest/APIReference/API_CreateClusterSecurityGroup.html
def create_cluster_security_group(options = {})
cluster_security_group_name = options[:cluster_security_group_name]
description = options[:description]
path = "/"
params = {
:headers => {},
:path => path,
:method => :put,
:query => {},
:parser => Fog::Parsers::Redshift::AWS::CreateClusterSecurityGroup.new
}
params[:query]['Action'] = 'CreateClusterSecurityGroup'
params[:query]['ClusterSecurityGroupName'] = cluster_security_group_name if cluster_security_group_name
params[:query]['Description'] = description if description
request(params)
end
end
end
end
2014-02-19 12:30:59 +00:00
end