Class: Formatron::CloudFormation::Template::VPC::Subnet
- Inherits:
-
Object
- Object
- Formatron::CloudFormation::Template::VPC::Subnet
- Defined in:
- lib/formatron/cloud_formation/template/vpc/subnet.rb,
lib/formatron/cloud_formation/template/vpc/subnet/acl.rb,
lib/formatron/cloud_formation/template/vpc/subnet/nat.rb,
lib/formatron/cloud_formation/template/vpc/subnet/bastion.rb,
lib/formatron/cloud_formation/template/vpc/subnet/instance.rb,
lib/formatron/cloud_formation/template/vpc/subnet/chef_server.rb,
lib/formatron/cloud_formation/template/vpc/subnet/instance/setup.rb,
lib/formatron/cloud_formation/template/vpc/subnet/instance/policy.rb,
lib/formatron/cloud_formation/template/vpc/subnet/instance/block_devices.rb,
lib/formatron/cloud_formation/template/vpc/subnet/instance/security_group.rb
Overview
generates CloudFormation subnet resources rubocop:disable Metrics/ClassLength
Defined Under Namespace
Classes: ACL, Bastion, ChefServer, Instance, NAT
Constant Summary collapse
- SUBNET_PREFIX =
'subnet'
- SUBNET_ROUTE_TABLE_ASSOCIATION_PREFIX =
'subnetRouteTableAssociation'
Instance Method Summary collapse
-
#initialize(subnet:, external:, vpc_guid:, vpc_cidr:, key_pair:, administrator_name:, administrator_password:, hosted_zone_name:, kms_key:, nats:, private_hosted_zone_id:, public_hosted_zone_id:, bucket:, name:, target:) ⇒ Subnet
constructor
rubocop:disable Metrics/MethodLength rubocop:disable Metrics/ParameterLists rubocop:disable Metrics/AbcSize.
-
#merge(resources:, outputs:) ⇒ Object
rubocop:disable Metrics/MethodLength.
Constructor Details
#initialize(subnet:, external:, vpc_guid:, vpc_cidr:, key_pair:, administrator_name:, administrator_password:, hosted_zone_name:, kms_key:, nats:, private_hosted_zone_id:, public_hosted_zone_id:, bucket:, name:, target:) ⇒ Subnet
rubocop:disable Metrics/MethodLength rubocop:disable Metrics/ParameterLists rubocop:disable Metrics/AbcSize
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
# File 'lib/formatron/cloud_formation/template/vpc/subnet.rb', line 22 def initialize( subnet:, external:, vpc_guid:, vpc_cidr:, key_pair:, administrator_name:, administrator_password:, hosted_zone_name:, kms_key:, nats:, private_hosted_zone_id:, public_hosted_zone_id:, bucket:, name:, target: ) @subnet = subnet @external = external @vpc_guid = vpc_guid @vpc_cidr = vpc_cidr @cidr = @subnet.cidr @acl = @subnet.acl @key_pair = key_pair @administrator_name = administrator_name @administrator_password = administrator_password @hosted_zone_name = hosted_zone_name @kms_key = kms_key @nats = nats @private_hosted_zone_id = private_hosted_zone_id @public_hosted_zone_id = public_hosted_zone_id @bucket = bucket @name = name @target = target end |
Instance Method Details
#merge(resources:, outputs:) ⇒ Object
rubocop:disable Metrics/MethodLength
62 63 64 65 66 67 68 69 70 |
# File 'lib/formatron/cloud_formation/template/vpc/subnet.rb', line 62 def merge(resources:, outputs:) @guid = @subnet.guid if @guid.nil? @guid = @external.guid _merge_external resources: resources, outputs: outputs else _merge_local resources: resources, outputs: outputs end end |