Sha256: 63b7c62b4f42f5f27e27a6b0c0a611da1be1e55ec3b1fa8956228ffbbb36f409

Contents?: true

Size: 1.01 KB

Versions: 100

Compression:

Stored size: 1.01 KB

Contents

require_relative '../resource'

module Convection
  module DSL
    module Template
      module Resource
        ##
        # Add DSL for VPCGatewayAttachment
        ##
        module EC2InternetGateway
          def attach_to_vpc(vpc, &block)
            a = Model::Template::Resource::EC2VPCGatewayAttachment.new("#{ name }VPCAttachment#{ vpc.name }", self)
            a.vpc(vpc)
            a.internet_gateway(self)

            a.instance_exec(&block) if block
            @template.resources[a.name] = a
          end
        end
      end
    end
  end

  module Model
    class Template
      class Resource
        ##
        # AWS::EC2::InternetGateway
        ##
        class EC2InternetGateway < Resource
          include Model::Mixin::Taggable
          include DSL::Template::Resource::EC2InternetGateway
          type 'AWS::EC2::InternetGateway'

          def render(*args)
            super.tap do |resource|
              render_tags(resource)
            end
          end
        end
      end
    end
  end
end

Version data entries

100 entries across 100 versions & 1 rubygems

Version Path
convection-2.3.1 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.3.0 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.29 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.28.pre.beta.2 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.28.pre.beta.1 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.27 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.26 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.25 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.24 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.23 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.22 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.21 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.20 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.19 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.18 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.17 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.16 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.15 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.14 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb
convection-2.2.13 lib/convection/model/template/resource/aws_ec2_internet_gateway.rb