CfnClientVpnRouteProps Struct
Properties for defining a CfnClientVpnRoute.
| Source | |
|---|---|
| Type last changed |
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ec2 as ec2 } from 'aws-cdk-lib';
const cfnClientVpnRouteProps: ec2.CfnClientVpnRouteProps = {
clientVpnEndpointId: 'clientVpnEndpointId',
destinationCidrBlock: 'destinationCidrBlock',
// the properties below are optional
description: 'description',
targetVpcSubnetId: 'targetVpcSubnetId',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_ec2 as ec2
cfn_client_vpn_route_props = ec2.CfnClientVpnRouteProps(
client_vpn_endpoint_id="clientVpnEndpointId",
destination_cidr_block="destinationCidrBlock",
# the properties below are optional
description="description",
target_vpc_subnet_id="targetVpcSubnetId"
)
java
// 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.*;
CfnClientVpnRouteProps cfnClientVpnRouteProps = CfnClientVpnRouteProps.builder()
.clientVpnEndpointId("clientVpnEndpointId")
.destinationCidrBlock("destinationCidrBlock")
// the properties below are optional
.description("description")
.targetVpcSubnetId("targetVpcSubnetId")
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.EC2;
var cfnClientVpnRouteProps = new CfnClientVpnRouteProps {
ClientVpnEndpointId = "clientVpnEndpointId",
DestinationCidrBlock = "destinationCidrBlock",
// the properties below are optional
Description = "description",
TargetVpcSubnetId = "targetVpcSubnetId"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
cfnClientVpnRouteProps := &CfnClientVpnRouteProps{
ClientVpnEndpointId: jsii.String("clientVpnEndpointId"),
DestinationCidrBlock: jsii.String("destinationCidrBlock"),
// the properties below are optional
Description: jsii.String("description"),
TargetVpcSubnetId: jsii.String("targetVpcSubnetId"),
}
Properties
clientVpnEndpointIdstringclient_vpn_endpoint_idstrclientVpnEndpointIdStringClientVpnEndpointIdstringClientVpnEndpointId*string required #The ID of the Client VPN endpoint to which to add the route.
descriptionoptionalstringdescriptionoptionalstrdescriptionoptionalStringDescriptionoptionalstringDescriptionoptional*string #A brief description of the route.
destinationCidrBlockstringdestination_cidr_blockstrdestinationCidrBlockStringDestinationCidrBlockstringDestinationCidrBlock*string required #The IPv4 address range, in CIDR notation, of the route destination. For example:.
notes
- To add a route for Internet access, enter
0.0.0.0/0 - To add a route for a peered VPC, enter the peered VPC's IPv4 CIDR range
- To add a route for an on-premises network, enter the AWS Site-to-Site VPN connection's IPv4 CIDR range
- To add a route for the local network, enter the client CIDR range
targetVpcSubnetIdoptionalstringtarget_vpc_subnet_idoptionalstrtargetVpcSubnetIdoptionalStringTargetVpcSubnetIdoptionalstringTargetVpcSubnetIdoptional*string #The ID of the subnet through which you want to route traffic.
The specified subnet must be an existing target network of the Client VPN endpoint.
Alternatively, if you're adding a route for the local network, specify local .