Class: Awsum::Ec2::SecurityGroup
- Defined in:
- lib/awsum/ec2/security_group.rb
Defined Under Namespace
Classes: GroupPermission, IpPermission, Permission
Instance Attribute Summary collapse
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#group_permissions ⇒ Object
readonly
Returns the value of attribute group_permissions.
-
#ip_permissions ⇒ Object
readonly
Returns the value of attribute ip_permissions.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#owner_id ⇒ Object
readonly
Returns the value of attribute owner_id.
Instance Method Summary collapse
-
#authorize(arguments) ⇒ Object
Authorize access.
-
#delete ⇒ Object
Delete this SecurityGroup.
-
#initialize(ec2, name, description, owner_id, ip_permissions, group_permissions) ⇒ SecurityGroup
constructor
A new instance of SecurityGroup.
-
#revoke(arguments) ⇒ Object
Revoke access.
Constructor Details
#initialize(ec2, name, description, owner_id, ip_permissions, group_permissions) ⇒ SecurityGroup
Returns a new instance of SecurityGroup.
8 9 10 11 12 13 14 15 |
# File 'lib/awsum/ec2/security_group.rb', line 8 def initialize(ec2, name, description, owner_id, , ) @ec2 = ec2 @name = name @description = description @owner_id = owner_id @ip_permissions = @group_permissions = end |
Instance Attribute Details
#description ⇒ Object (readonly)
Returns the value of attribute description.
6 7 8 |
# File 'lib/awsum/ec2/security_group.rb', line 6 def description @description end |
#group_permissions ⇒ Object (readonly)
Returns the value of attribute group_permissions.
6 7 8 |
# File 'lib/awsum/ec2/security_group.rb', line 6 def @group_permissions end |
#ip_permissions ⇒ Object (readonly)
Returns the value of attribute ip_permissions.
6 7 8 |
# File 'lib/awsum/ec2/security_group.rb', line 6 def @ip_permissions end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
6 7 8 |
# File 'lib/awsum/ec2/security_group.rb', line 6 def name @name end |
#owner_id ⇒ Object (readonly)
Returns the value of attribute owner_id.
6 7 8 |
# File 'lib/awsum/ec2/security_group.rb', line 6 def owner_id @owner_id end |
Instance Method Details
#authorize(arguments) ⇒ Object
Authorize access
Options:
See Ec2#authorize_security_group_ingress
21 22 23 |
# File 'lib/awsum/ec2/security_group.rb', line 21 def (arguments) @ec2.(@name, arguments) end |
#delete ⇒ Object
Delete this SecurityGroup
34 35 36 |
# File 'lib/awsum/ec2/security_group.rb', line 34 def delete @ec2.delete_security_group(@name) end |
#revoke(arguments) ⇒ Object
Revoke access
Options:
See Ec2#revoke_security_group_ingress
29 30 31 |
# File 'lib/awsum/ec2/security_group.rb', line 29 def revoke(arguments) @ec2.revoke_security_group_ingress(@name, arguments) end |