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 |
Allocates an Elastic IP address.
An Elastic IP address is for use either in the EC2-Classic platform or in a VPC. By default, you can allocate 5 Elastic IP addresses for EC2-Classic per region and 5 Elastic IP addresses for EC2-VPC per region.
If you release an Elastic IP address for use in a VPC, you might be able to recover it. To recover an Elastic IP address that you released, specify it in the Address
parameter. Note that you cannot recover an Elastic IP address that you released after it is allocated to another AWS account.
For more information, see Elastic IP Addresses in the Amazon Elastic Compute Cloud User Guide .
- allocateAddress :: AllocateAddress
- data AllocateAddress
- aaDomain :: Lens' AllocateAddress (Maybe DomainType)
- aaAddress :: Lens' AllocateAddress (Maybe Text)
- aaDryRun :: Lens' AllocateAddress (Maybe Bool)
- allocateAddressResponse :: Int -> AllocateAddressResponse
- data AllocateAddressResponse
- aarsAllocationId :: Lens' AllocateAddressResponse (Maybe Text)
- aarsDomain :: Lens' AllocateAddressResponse (Maybe DomainType)
- aarsPublicIP :: Lens' AllocateAddressResponse (Maybe Text)
- aarsResponseStatus :: Lens' AllocateAddressResponse Int
Creating a Request
allocateAddress :: AllocateAddress Source #
Creates a value of AllocateAddress
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
aaDomain
- Set tovpc
to allocate the address for use with instances in a VPC. Default: The address is for use with instances in EC2-Classic.aaAddress
- [EC2-VPC] The Elastic IP address to recover.aaDryRun
- Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response isDryRunOperation
. Otherwise, it isUnauthorizedOperation
.
data AllocateAddress Source #
Contains the parameters for AllocateAddress.
See: allocateAddress
smart constructor.
Request Lenses
aaDomain :: Lens' AllocateAddress (Maybe DomainType) Source #
Set to vpc
to allocate the address for use with instances in a VPC. Default: The address is for use with instances in EC2-Classic.
aaDryRun :: Lens' AllocateAddress (Maybe Bool) Source #
Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation
. Otherwise, it is UnauthorizedOperation
.
Destructuring the Response
allocateAddressResponse Source #
Creates a value of AllocateAddressResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
aarsAllocationId
- [EC2-VPC] The ID that AWS assigns to represent the allocation of the Elastic IP address for use with instances in a VPC.aarsDomain
- Indicates whether this Elastic IP address is for use with instances in EC2-Classic (standard
) or instances in a VPC (vpc
).aarsPublicIP
- The Elastic IP address.aarsResponseStatus
- -- | The response status code.
data AllocateAddressResponse Source #
Contains the output of AllocateAddress.
See: allocateAddressResponse
smart constructor.
Response Lenses
aarsAllocationId :: Lens' AllocateAddressResponse (Maybe Text) Source #
- EC2-VPC
- The ID that AWS assigns to represent the allocation of the Elastic IP address for use with instances in a VPC.
aarsDomain :: Lens' AllocateAddressResponse (Maybe DomainType) Source #
Indicates whether this Elastic IP address is for use with instances in EC2-Classic (standard
) or instances in a VPC (vpc
).
aarsPublicIP :: Lens' AllocateAddressResponse (Maybe Text) Source #
The Elastic IP address.
aarsResponseStatus :: Lens' AllocateAddressResponse Int Source #
- - | The response status code.