Copyright | (c) 2013-2018 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Creates an Application Load Balancer or a Network Load Balancer.
When you create a load balancer, you can specify security groups, public subnets, IP address type, and tags. Otherwise, you could do so later using SetSecurityGroups
, SetSubnets
, SetIpAddressType
, and AddTags
.
To create listeners for your load balancer, use CreateListener
. To describe your current load balancers, see DescribeLoadBalancers
. When you are finished with a load balancer, you can delete it using DeleteLoadBalancer
.
For limit information, see Limits for Your Application Load Balancer in the Application Load Balancers Guide and Limits for Your Network Load Balancer in the Network Load Balancers Guide .
This operation is idempotent, which means that it completes at most one time. If you attempt to create multiple load balancers with the same settings, each call succeeds.
For more information, see Application Load Balancers in the Application Load Balancers Guide and Network Load Balancers in the Network Load Balancers Guide .
- createLoadBalancer :: Text -> CreateLoadBalancer
- data CreateLoadBalancer
- clbSubnetMappings :: Lens' CreateLoadBalancer [SubnetMapping]
- clbSecurityGroups :: Lens' CreateLoadBalancer [Text]
- clbSubnets :: Lens' CreateLoadBalancer [Text]
- clbIPAddressType :: Lens' CreateLoadBalancer (Maybe IPAddressType)
- clbScheme :: Lens' CreateLoadBalancer (Maybe LoadBalancerSchemeEnum)
- clbType :: Lens' CreateLoadBalancer (Maybe LoadBalancerTypeEnum)
- clbTags :: Lens' CreateLoadBalancer (Maybe (NonEmpty Tag))
- clbName :: Lens' CreateLoadBalancer Text
- createLoadBalancerResponse :: Int -> CreateLoadBalancerResponse
- data CreateLoadBalancerResponse
- clbrsLoadBalancers :: Lens' CreateLoadBalancerResponse [LoadBalancer]
- clbrsResponseStatus :: Lens' CreateLoadBalancerResponse Int
Creating a Request
Creates a value of CreateLoadBalancer
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
clbSubnetMappings
- The IDs of the public subnets. You can specify only one subnet per Availability Zone. You must specify either subnets or subnet mappings. [Application Load Balancers] You must specify subnets from at least two Availability Zones. You cannot specify Elastic IP addresses for your subnets. [Network Load Balancers] You can specify subnets from one or more Availability Zones. You can specify one Elastic IP address per subnet.clbSecurityGroups
- [Application Load Balancers] The IDs of the security groups for the load balancer.clbSubnets
- The IDs of the public subnets. You can specify only one subnet per Availability Zone. You must specify either subnets or subnet mappings. [Application Load Balancers] You must specify subnets from at least two Availability Zones. [Network Load Balancers] You can specify subnets from one or more Availability Zones.clbIPAddressType
- [Application Load Balancers] The type of IP addresses used by the subnets for your load balancer. The possible values areipv4
(for IPv4 addresses) anddualstack
(for IPv4 and IPv6 addresses). Internal load balancers must useipv4
.clbScheme
- The nodes of an Internet-facing load balancer have public IP addresses. The DNS name of an Internet-facing load balancer is publicly resolvable to the public IP addresses of the nodes. Therefore, Internet-facing load balancers can route requests from clients over the Internet. The nodes of an internal load balancer have only private IP addresses. The DNS name of an internal load balancer is publicly resolvable to the private IP addresses of the nodes. Therefore, internal load balancers can only route requests from clients with access to the VPC for the load balancer. The default is an Internet-facing load balancer.clbType
- The type of load balancer. The default isapplication
.clbTags
- One or more tags to assign to the load balancer.clbName
- The name of the load balancer. This name must be unique per region per account, can have a maximum of 32 characters, must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
data CreateLoadBalancer Source #
See: createLoadBalancer
smart constructor.
Request Lenses
clbSubnetMappings :: Lens' CreateLoadBalancer [SubnetMapping] Source #
The IDs of the public subnets. You can specify only one subnet per Availability Zone. You must specify either subnets or subnet mappings. [Application Load Balancers] You must specify subnets from at least two Availability Zones. You cannot specify Elastic IP addresses for your subnets. [Network Load Balancers] You can specify subnets from one or more Availability Zones. You can specify one Elastic IP address per subnet.
clbSecurityGroups :: Lens' CreateLoadBalancer [Text] Source #
- Application Load Balancers
- The IDs of the security groups for the load balancer.
clbSubnets :: Lens' CreateLoadBalancer [Text] Source #
The IDs of the public subnets. You can specify only one subnet per Availability Zone. You must specify either subnets or subnet mappings. [Application Load Balancers] You must specify subnets from at least two Availability Zones. [Network Load Balancers] You can specify subnets from one or more Availability Zones.
clbIPAddressType :: Lens' CreateLoadBalancer (Maybe IPAddressType) Source #
- Application Load Balancers
- The type of IP addresses used by the subnets for your load balancer. The possible values are
ipv4
(for IPv4 addresses) anddualstack
(for IPv4 and IPv6 addresses). Internal load balancers must useipv4
.
clbScheme :: Lens' CreateLoadBalancer (Maybe LoadBalancerSchemeEnum) Source #
The nodes of an Internet-facing load balancer have public IP addresses. The DNS name of an Internet-facing load balancer is publicly resolvable to the public IP addresses of the nodes. Therefore, Internet-facing load balancers can route requests from clients over the Internet. The nodes of an internal load balancer have only private IP addresses. The DNS name of an internal load balancer is publicly resolvable to the private IP addresses of the nodes. Therefore, internal load balancers can only route requests from clients with access to the VPC for the load balancer. The default is an Internet-facing load balancer.
clbType :: Lens' CreateLoadBalancer (Maybe LoadBalancerTypeEnum) Source #
The type of load balancer. The default is application
.
clbTags :: Lens' CreateLoadBalancer (Maybe (NonEmpty Tag)) Source #
One or more tags to assign to the load balancer.
clbName :: Lens' CreateLoadBalancer Text Source #
The name of the load balancer. This name must be unique per region per account, can have a maximum of 32 characters, must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
Destructuring the Response
createLoadBalancerResponse Source #
Creates a value of CreateLoadBalancerResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
clbrsLoadBalancers
- Information about the load balancer.clbrsResponseStatus
- -- | The response status code.
data CreateLoadBalancerResponse Source #
See: createLoadBalancerResponse
smart constructor.
Response Lenses
clbrsLoadBalancers :: Lens' CreateLoadBalancerResponse [LoadBalancer] Source #
Information about the load balancer.
clbrsResponseStatus :: Lens' CreateLoadBalancerResponse Int Source #
- - | The response status code.