@Stability(value=Stable)
public static interface CfnLaunchTemplate.NetworkInterfaceProperty
extends software.amazon.jsii.JsiiSerializable
NetworkInterface is a property of AWS::EC2::LaunchTemplate LaunchTemplateData .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.ec2.*;
NetworkInterfaceProperty networkInterfaceProperty = NetworkInterfaceProperty.builder()
.associateCarrierIpAddress(false)
.associatePublicIpAddress(false)
.deleteOnTermination(false)
.description("description")
.deviceIndex(123)
.groups(List.of("groups"))
.interfaceType("interfaceType")
.ipv4PrefixCount(123)
.ipv4Prefixes(List.of(Ipv4PrefixSpecificationProperty.builder()
.ipv4Prefix("ipv4Prefix")
.build()))
.ipv6AddressCount(123)
.ipv6Addresses(List.of(Ipv6AddProperty.builder()
.ipv6Address("ipv6Address")
.build()))
.ipv6PrefixCount(123)
.ipv6Prefixes(List.of(Ipv6PrefixSpecificationProperty.builder()
.ipv6Prefix("ipv6Prefix")
.build()))
.networkCardIndex(123)
.networkInterfaceId("networkInterfaceId")
.privateIpAddress("privateIpAddress")
.privateIpAddresses(List.of(PrivateIpAddProperty.builder()
.primary(false)
.privateIpAddress("privateIpAddress")
.build()))
.secondaryPrivateIpAddressCount(123)
.subnetId("subnetId")
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
CfnLaunchTemplate.NetworkInterfaceProperty.Builder
A builder for
CfnLaunchTemplate.NetworkInterfaceProperty |
static class |
CfnLaunchTemplate.NetworkInterfaceProperty.Jsii$Proxy
An implementation for
CfnLaunchTemplate.NetworkInterfaceProperty |
| Modifier and Type | Method and Description |
|---|---|
static CfnLaunchTemplate.NetworkInterfaceProperty.Builder |
builder() |
default Object |
getAssociateCarrierIpAddress()
Indicates whether to associate a Carrier IP address with eth0 for a new network interface.
|
default Object |
getAssociatePublicIpAddress()
Associates a public IPv4 address with eth0 for a new network interface.
|
default Object |
getDeleteOnTermination()
Indicates whether the network interface is deleted when the instance is terminated.
|
default String |
getDescription()
A description for the network interface.
|
default Number |
getDeviceIndex()
The device index for the network interface attachment.
|
default List<String> |
getGroups()
The IDs of one or more security groups.
|
default String |
getInterfaceType()
The type of network interface.
|
default Number |
getIpv4PrefixCount()
The number of IPv4 prefixes to be automatically assigned to the network interface.
|
default Object |
getIpv4Prefixes()
One or more IPv4 prefixes to be assigned to the network interface.
|
default Number |
getIpv6AddressCount()
The number of IPv6 addresses to assign to a network interface.
|
default Object |
getIpv6Addresses()
One or more specific IPv6 addresses from the IPv6 CIDR block range of your subnet.
|
default Number |
getIpv6PrefixCount()
The number of IPv6 prefixes to be automatically assigned to the network interface.
|
default Object |
getIpv6Prefixes()
One or more IPv6 prefixes to be assigned to the network interface.
|
default Number |
getNetworkCardIndex()
The index of the network card.
|
default String |
getNetworkInterfaceId()
The ID of the network interface.
|
default String |
getPrivateIpAddress()
The primary private IPv4 address of the network interface.
|
default Object |
getPrivateIpAddresses()
One or more private IPv4 addresses.
|
default Number |
getSecondaryPrivateIpAddressCount()
The number of secondary private IPv4 addresses to assign to a network interface.
|
default String |
getSubnetId()
The ID of the subnet for the network interface.
|
@Stability(value=Stable) @Nullable default Object getAssociateCarrierIpAddress()
Use this option when you launch an instance in a Wavelength Zone and want to associate a Carrier IP address with the network interface. For more information about Carrier IP addresses, see Carrier IP addresses in the AWS Wavelength Developer Guide .
@Stability(value=Stable) @Nullable default Object getAssociatePublicIpAddress()
@Stability(value=Stable) @Nullable default Object getDeleteOnTermination()
@Stability(value=Stable) @Nullable default String getDescription()
@Stability(value=Stable) @Nullable default Number getDeviceIndex()
@Stability(value=Stable) @Nullable default List<String> getGroups()
@Stability(value=Stable) @Nullable default String getInterfaceType()
To create an Elastic Fabric Adapter (EFA), specify efa . For more information, see Elastic Fabric Adapter in the Amazon Elastic Compute Cloud User Guide .
If you are not creating an EFA, specify interface or omit this parameter.
Valid values: interface | efa
@Stability(value=Stable) @Nullable default Number getIpv4PrefixCount()
You cannot use this option if you use the Ipv4Prefix option.
@Stability(value=Stable) @Nullable default Object getIpv4Prefixes()
You cannot use this option if you use the Ipv4PrefixCount option.
@Stability(value=Stable) @Nullable default Number getIpv6AddressCount()
Amazon EC2 automatically selects the IPv6 addresses from the subnet range. You can't use this option if specifying specific IPv6 addresses.
@Stability(value=Stable) @Nullable default Object getIpv6Addresses()
You can't use this option if you're specifying a number of IPv6 addresses.
@Stability(value=Stable) @Nullable default Number getIpv6PrefixCount()
You cannot use this option if you use the Ipv6Prefix option.
@Stability(value=Stable) @Nullable default Object getIpv6Prefixes()
You cannot use this option if you use the Ipv6PrefixCount option.
@Stability(value=Stable) @Nullable default Number getNetworkCardIndex()
Some instance types support multiple network cards. The primary network interface must be assigned to network card index 0. The default is network card index 0.
@Stability(value=Stable) @Nullable default String getNetworkInterfaceId()
@Stability(value=Stable) @Nullable default String getPrivateIpAddress()
@Stability(value=Stable) @Nullable default Object getPrivateIpAddresses()
@Stability(value=Stable) @Nullable default Number getSecondaryPrivateIpAddressCount()
@Stability(value=Stable) @Nullable default String getSubnetId()
@Stability(value=Stable) static CfnLaunchTemplate.NetworkInterfaceProperty.Builder builder()
Copyright © 2022. All rights reserved.