Class: ElasticBeans::Network
- Inherits:
-
Object
- Object
- ElasticBeans::Network
show all
- Defined in:
- lib/elastic_beans/network.rb
Overview
The networking CloudFormation stack provided to configure.
Defined Under Namespace
Classes: MissingNetworkingError
Constant Summary
collapse
- APPLICATION_SECURITY_GROUP_KEY =
"ApplicationSecurityGroup"
- APPLICATION_SUBNET_KEY =
"ApplicationSubnet"
- APPLICATION_SUBNET_KEY_PATTERN =
/\AApplicationSubnet\d*\z/
- ELB_SECURITY_GROUP_KEY =
"ELBSecurityGroup"
- ELB_SUBNET_KEY =
"ELBSubnet"
- ELB_SUBNET_KEY_PATTERN =
/\AELBSubnet\d*\z/
- SSH_SECURITY_GROUP_KEY =
"SSHSecurityGroup"
- VPC_KEY =
"VpcId"
Instance Method Summary
collapse
Constructor Details
#initialize(stack_name:, cloudformation:) ⇒ Network
Returns a new instance of Network.
15
16
17
|
# File 'lib/elastic_beans/network.rb', line 15
def initialize(stack_name:, cloudformation:)
@stack = ElasticBeans::Aws::CloudformationStack.new(stack_name, cloudformation: cloudformation)
end
|
Instance Method Details
#application_security_groups ⇒ Object
#application_subnets ⇒ Object
#elb_security_groups ⇒ Object
31
32
33
|
# File 'lib/elastic_beans/network.rb', line 31
def elb_security_groups
[stack.stack_output(ELB_SECURITY_GROUP_KEY)]
end
|
#ssh_security_group ⇒ Object
43
44
45
|
# File 'lib/elastic_beans/network.rb', line 43
def ssh_security_group
stack.stack_output(SSH_SECURITY_GROUP_KEY)
end
|
#vpc ⇒ Object
47
48
49
|
# File 'lib/elastic_beans/network.rb', line 47
def vpc
stack.stack_output(VPC_KEY)
end
|