Method: Fog::Compute::AWS::Real#authorize_security_group_ingress
- Defined in:
- lib/fog/compute/requests/aws/authorize_security_group_ingress.rb
#authorize_security_group_ingress(group_name, options = {}) ⇒ Object
Add permissions to a security group
Parameters
-
group_name<~String> - Name of group
-
options<~Hash>:
-
‘SourceSecurityGroupName’<~String> - Name of security group to authorize
-
‘SourceSecurityGroupOwnerId’<~String> - Name of owner to authorize
or
-
‘CidrIp’ - CIDR range
-
‘FromPort’ - Start of port range (or -1 for ICMP wildcard)
-
‘GroupName’ - Name of group to modify
-
‘IpProtocol’ - Ip protocol, must be in [‘tcp’, ‘udp’, ‘icmp’]
-
‘ToPort’ - End of port range (or -1 for ICMP wildcard)
-
Returns
-
response<~Excon::Response>:
-
body<~Hash>:
-
‘requestId’<~String> - Id of request
-
‘return’<~Boolean> - success?
-
-
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/fog/compute/requests/aws/authorize_security_group_ingress.rb', line 29 def (group_name, = {}) if group_name.is_a?(Hash) location = caller.first warning = "[yellow][WARN] Fog::AWS::Compute#authorize_security_group_ingress now requires the 'group_name' parameter. Only specifying an options hash is now deprecated" warning << " [light_black](" << location << ")[/] " Formatador.display_line(warning) = group_name group_name = ['GroupName'] end request({ 'Action' => 'AuthorizeSecurityGroupIngress', 'GroupName' => group_name, :idempotent => true, :parser => Fog::Parsers::Compute::AWS::Basic.new }.merge!()) end |