Class: Convection::Model::Template::Resource::EC2SecurityGroup
- Inherits:
-
Convection::Model::Template::Resource
- Object
- Convection::Model::Template::Resource
- Convection::Model::Template::Resource::EC2SecurityGroup
- Defined in:
- lib/convection/model/template/resource/aws_ec2_security_group.rb
Overview
AWS::EC2::SecurityGroup
Defined Under Namespace
Classes: Rule
Instance Attribute Summary collapse
-
#security_group_egress ⇒ Object
readonly
Returns the value of attribute security_group_egress.
-
#security_group_ingress ⇒ Object
readonly
Returns the value of attribute security_group_ingress.
Attributes inherited from Convection::Model::Template::Resource
#exist, #name, #parent, #properties, #resource_attributes, #template
Instance Method Summary collapse
- #description(value) ⇒ Object
-
#initialize(*args) ⇒ EC2SecurityGroup
constructor
A new instance of EC2SecurityGroup.
- #render(*args) ⇒ Object
- #vpc(value) ⇒ Object
Methods included from Mixin::Taggable
#immutable_metadata, #render_tags, #tag, #tags
Methods included from DSL::Template::Resource::EC2SecurityGroup
Methods inherited from Convection::Model::Template::Resource
#as_attribute, attach_method, #deletion_policy, #depends_on, properties, #property, property, #reference, type, #type, #with_output
Methods included from Mixin::Conditional
Methods included from DSL::Template::Resource
Methods included from DSL::Helpers
#camel_case, included, method_name, #screaming_snake_case, #snake_case
Methods included from DSL::IntrinsicFunctions
#base64, #find_in_map, #fn_and, #fn_equals, #fn_if, #fn_not, #fn_or, #fn_ref, #get_att, #get_azs, #join, #select
Constructor Details
#initialize(*args) ⇒ EC2SecurityGroup
Returns a new instance of EC2SecurityGroup
105 106 107 108 109 110 |
# File 'lib/convection/model/template/resource/aws_ec2_security_group.rb', line 105 def initialize(*args) super @security_group_ingress = [] @security_group_egress = [] end |
Instance Attribute Details
#security_group_egress ⇒ Object (readonly)
Returns the value of attribute security_group_egress
54 55 56 |
# File 'lib/convection/model/template/resource/aws_ec2_security_group.rb', line 54 def security_group_egress @security_group_egress end |
#security_group_ingress ⇒ Object (readonly)
Returns the value of attribute security_group_ingress
53 54 55 |
# File 'lib/convection/model/template/resource/aws_ec2_security_group.rb', line 53 def security_group_ingress @security_group_ingress end |
Instance Method Details
#description ⇒ Object #description(value) ⇒ Object
102 |
# File 'lib/convection/model/template/resource/aws_ec2_security_group.rb', line 102 property :description, 'GroupDescription' |
#render(*args) ⇒ Object
112 113 114 115 116 117 118 |
# File 'lib/convection/model/template/resource/aws_ec2_security_group.rb', line 112 def render(*args) super.tap do |resource| resource['Properties']['SecurityGroupIngress'] = security_group_ingress.map(&:render) resource['Properties']['SecurityGroupEgress'] = security_group_egress.map(&:render) (resource) end end |
#vpc ⇒ Object #vpc(value) ⇒ Object
103 |
# File 'lib/convection/model/template/resource/aws_ec2_security_group.rb', line 103 property :vpc, 'VpcId' |