Endpoint class
Provides an AWS Client VPN endpoint for OpenVPN clients. For more information on usage, please see the AWS Client VPN Administrator's Guide.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.ec2clientvpn.Endpoint("example", {
connectionLogOptions: {
enabled: true,
cloudwatchLogGroup: lg.name,
cloudwatchLogStream: ls.name,
},
authenticationOptions: [{
type: "certificate-authentication",
rootCertificateChainArn: rootCert.arn,
}],
description: "clientvpn-example",
serverCertificateArn: cert.arn,
clientCidrBlock: "10.0.0.0/16",
});
import pulumi
import pulumi_aws as aws
example = aws.ec2clientvpn.Endpoint("example",
connection_log_options={
"enabled": True,
"cloudwatch_log_group": lg["name"],
"cloudwatch_log_stream": ls["name"],
},
authentication_options=[{
"type": "certificate-authentication",
"root_certificate_chain_arn": root_cert["arn"],
}],
description="clientvpn-example",
server_certificate_arn=cert["arn"],
client_cidr_block="10.0.0.0/16")
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.Ec2ClientVpn.Endpoint("example", new()
{
ConnectionLogOptions = new Aws.Ec2ClientVpn.Inputs.EndpointConnectionLogOptionsArgs
{
Enabled = true,
CloudwatchLogGroup = lg.Name,
CloudwatchLogStream = ls.Name,
},
AuthenticationOptions = new[]
{
new Aws.Ec2ClientVpn.Inputs.EndpointAuthenticationOptionArgs
{
Type = "certificate-authentication",
RootCertificateChainArn = rootCert.Arn,
},
},
Description = "clientvpn-example",
ServerCertificateArn = cert.Arn,
ClientCidrBlock = "10.0.0.0/16",
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/ec2clientvpn"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2clientvpn.NewEndpoint(ctx, "example", &ec2clientvpn.EndpointArgs{
ConnectionLogOptions: &ec2clientvpn.EndpointConnectionLogOptionsArgs{
Enabled: pulumi.Bool(true),
CloudwatchLogGroup: pulumi.Any(lg.Name),
CloudwatchLogStream: pulumi.Any(ls.Name),
},
AuthenticationOptions: ec2clientvpn.EndpointAuthenticationOptionArray{
&ec2clientvpn.EndpointAuthenticationOptionArgs{
Type: pulumi.String("certificate-authentication"),
RootCertificateChainArn: pulumi.Any(rootCert.Arn),
},
},
Description: pulumi.String("clientvpn-example"),
ServerCertificateArn: pulumi.Any(cert.Arn),
ClientCidrBlock: pulumi.String("10.0.0.0/16"),
})
if err != nil {
return err
}
return nil
})
}
pulumi {
required_providers {
aws = {
source = "pulumi/aws"
}
}
}
resource "aws_ec2clientvpn_endpoint" "example" {
connection_log_options = {
enabled = true
cloudwatch_log_group = lg.name
cloudwatch_log_stream = ls.name
}
authentication_options {
type = "certificate-authentication"
root_certificate_chain_arn = rootCert.arn
}
description = "clientvpn-example"
server_certificate_arn = cert.arn
client_cidr_block = "10.0.0.0/16"
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2clientvpn.Endpoint;
import com.pulumi.aws.ec2clientvpn.EndpointArgs;
import com.pulumi.aws.ec2clientvpn.inputs.EndpointConnectionLogOptionsArgs;
import com.pulumi.aws.ec2clientvpn.inputs.EndpointAuthenticationOptionArgs;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Endpoint("example", EndpointArgs.builder()
.connectionLogOptions(EndpointConnectionLogOptionsArgs.builder()
.enabled(true)
.cloudwatchLogGroup(lg.name())
.cloudwatchLogStream(ls.name())
.build())
.authenticationOptions(EndpointAuthenticationOptionArgs.builder()
.type("certificate-authentication")
.rootCertificateChainArn(rootCert.arn())
.build())
.description("clientvpn-example")
.serverCertificateArn(cert.arn())
.clientCidrBlock("10.0.0.0/16")
.build());
}
}
resources:
example:
type: aws:ec2clientvpn:Endpoint
properties:
connectionLogOptions:
enabled: true
cloudwatchLogGroup: ${lg.name}
cloudwatchLogStream: ${ls.name}
authenticationOptions:
- type: certificate-authentication
rootCertificateChainArn: ${rootCert.arn}
description: clientvpn-example
serverCertificateArn: ${cert.arn}
clientCidrBlock: 10.0.0.0/16
Import
Using pulumi import, import AWS Client VPN endpoints using the id value found via aws ec2 describe-client-vpn-endpoints. For example:
$ pulumi import aws:ec2clientvpn/endpoint:Endpoint example cvpn-endpoint-0ac3a1abbccddd666
Constructors
- Endpoint(String name, {EndpointArgs? args, CustomResourceOptions? options})
-
Creates a new Endpoint.
nameThe Pulumi resource name.argsArguments used to configure this Endpoint. The set of arguments for Endpoint.optionsResource options controlling this resource's behavior. - Endpoint.reference(String urn)
- Creates a typed reference to an existing Endpoint resource.
Properties
-
arn
↔ Output<
String> -
The ARN of the Client VPN endpoint.
latefinal
-
authenticationOptions
↔ Output<
List< EndpointAuthenticationOption> > -
Information about the authentication method to be used to authenticate clients. See
authenticationOptionsBlock Reference below for details.latefinal -
childResources
→ Set<
Resource> -
finalinherited
-
clientCidrBlock
↔ Output<
String?> -
The IPv4 address range, in CIDR notation, from which to assign client IP addresses. The address range cannot overlap with the local CIDR of the VPC in which the associated subnet is located, or the routes that you add manually. The address range cannot be changed after the Client VPN endpoint has been created. The CIDR block should be /22 or greater. When
trafficIpAddressTypeis set toipv6, it must not be specified. Otherwise, it is required.latefinal -
clientConnectOptions
↔ Output<
EndpointClientConnectOptions> -
The options for managing connection authorization for new client connections. See
clientConnectOptionsBlock Reference below for details.latefinal -
clientLoginBannerOptions
↔ Output<
EndpointClientLoginBannerOptions> -
Options for enabling a customizable text banner that will be displayed on AWS provided clients when a VPN session is established. See
clientLoginBannerOptionsBlock Reference below for details.latefinal -
clientRouteEnforcementOptions
↔ Output<
EndpointClientRouteEnforcementOptions> -
Options for enforce administrator defined routes on devices connected through the VPN. See
clientRouteEnforcementOptionsBlock Reference below for details.latefinal -
completionSources
↔ Map<
String, IOutputCompletionSource> -
latefinalinherited
-
connectionLogOptions
↔ Output<
EndpointConnectionLogOptions> -
Information about the client connection logging options. See
connectionLogOptionsBlock Reference below for details.latefinal -
description
↔ Output<
String?> -
A brief description of the Client VPN endpoint.
latefinal
-
disconnectOnSessionTimeout
↔ Output<
bool> -
Indicates whether the client VPN session is disconnected after the maximum
sessionTimeoutHoursis reached. Iftrue, users are prompted to reconnect client VPN. Iffalse, client VPN attempts to reconnect automatically. The default value isfalse.latefinal -
dnsName
↔ Output<
String> -
The DNS name to be used by clients when establishing their VPN session.
latefinal
-
dnsServers
↔ Output<
List< String> ?> -
Information about the DNS servers to be used for DNS resolution. A Client VPN endpoint can have up to two DNS servers. If no DNS server is specified, the DNS address of the connecting device is used.
latefinal
-
endpointIpAddressType
↔ Output<
String> -
IP address type for the Client VPN endpoint. Valid values are
ipv4,ipv6, ordual-stack. Defaults toipv4.latefinal - hashCode → int
-
The hash code for this object.
no setterinherited
-
id
↔ Output<
String> -
getter/setter pairinherited
- isCustom → bool
-
Returns whether this resource is provider-managed.
no setterinherited
- isProtected → bool
-
Returns whether this resource is protected from deletion.
no setterinherited
- isRemote → bool
-
Whether this resource is registered as remote.
no setterinherited
- isResourceReference → bool
-
Whether this instance represents a resource value returned over RPC.
finalinherited
-
region
↔ Output<
String> -
Region where this resource will be managed. Defaults to the Region set in the provider configuration.
latefinal
-
resourceTransforms
→ List<
ResourceTransform> -
Inherited/explicit async transforms.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
securityGroupIds
↔ Output<
List< String> > -
The IDs of one or more security groups to apply to the target network. You must also specify the ID of the VPC that contains the security groups. Conflicts with
transitGatewayConfiguration.latefinal -
selfServicePortal
↔ Output<
String?> -
Specify whether to enable the self-service portal for the Client VPN endpoint. Values can be
enabledordisabled. Default value isdisabled.latefinal -
selfServicePortalUrl
↔ Output<
String> -
The URL of the self-service portal.
latefinal
-
serverCertificateArn
↔ Output<
String> -
The ARN of the ACM server certificate.
latefinal
-
sessionTimeoutHours
↔ Output<
int?> -
The maximum session duration is a trigger by which end-users are required to re-authenticate prior to establishing a VPN session. Default value is
24- Valid values:8 | 10 | 12 | 24latefinal -
splitTunnel
↔ Output<
bool?> -
Indicates whether split-tunnel is enabled on VPN endpoint. Default value is
false.latefinal -
A mapping of tags to assign to the resource. If configured with a provider
defaultTagsconfiguration block present, tags with matching keys will overwrite those defined at the provider-level.latefinal -
A map of tags assigned to the resource, including those inherited from the provider
defaultTagsconfiguration block.latefinal -
trafficIpAddressType
↔ Output<
String> -
IP address type for traffic within the Client VPN tunnel. Valid values are
ipv4,ipv6, ordual-stack. Defaults toipv4. When it is set toipv6,clientCidrBlockmust not be specified.latefinal -
transformations
→ List<
ResourceTransformation> -
Inherited/explicit legacy transformations.
no setterinherited
-
transitGatewayConfiguration
↔ Output<
EndpointTransitGatewayConfiguration> -
Configuration block for associating the Client VPN endpoint with a Transit Gateway. Conflicts with
vpcIdandsecurityGroupIds. SeetransitGatewayConfigurationBlock Reference below for details.latefinal -
transportProtocol
↔ Output<
String?> -
The transport protocol to be used by the VPN session. Default value is
udp.latefinal -
urn
↔ Output<
String> -
latefinalinherited
-
vpcId
↔ Output<
String> -
The ID of the VPC to associate with the Client VPN endpoint. If no security group IDs are specified in the request, the default security group for the VPC is applied. Conflicts with
transitGatewayConfiguration.latefinal -
vpnPort
↔ Output<
int?> -
The port number for the Client VPN endpoint. Valid values are
443and1194. Default value is443.latefinal
Methods
-
failId(
Object error) → void -
Completes this resource ID with an error when registration fails.
inherited
-
failOutputs(
Object error) → void -
Completes all output properties with
error.inherited -
failUrn(
Object error) → void -
Completes this resource URN with an error when registration fails.
inherited
-
getProvider(
String moduleMember) → ProviderResource? -
Returns provider for
moduleMember's package, if configured.inherited -
getResourceName(
) → String -
Returns this resource's logical name.
inherited
-
getResourceType(
) → String -
Returns this resource's Pulumi type token.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
registerOutput<
T> (String propertyName, {Object? decoder(Object?)?, bool isSecret = false}) → Output< T> -
Registers a dynamic output property for this resource.
inherited
-
resolveId(
String? value, {required bool isKnown}) → void -
Resolves the provider-assigned ID for this resource.
inherited
-
resolveOutputs(
Struct outputs) → void -
Resolves all output properties from a monitor response payload.
inherited
-
resolveUrn(
String value) → void -
Resolves this resource's URN once assigned by the engine.
inherited
-
serializeProperties(
Map< String, dynamic> properties) → Future<Struct> -
Serializes resource properties for RPC transmission.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited