VpcEndpointArgs

data class VpcEndpointArgs(val autoAccept: Output<Boolean>? = null, val dnsOptions: Output<VpcEndpointDnsOptionsArgs>? = null, val ipAddressType: Output<String>? = null, val policy: Output<String>? = null, val privateDnsEnabled: Output<Boolean>? = null, val resourceConfigurationArn: Output<String>? = null, val routeTableIds: Output<List<String>>? = null, val securityGroupIds: Output<List<String>>? = null, val serviceName: Output<String>? = null, val serviceNetworkArn: Output<String>? = null, val serviceRegion: Output<String>? = null, val subnetConfigurations: Output<List<VpcEndpointSubnetConfigurationArgs>>? = null, val subnetIds: Output<List<String>>? = null, val tags: Output<Map<String, String>>? = null, val vpcEndpointType: Output<String>? = null, val vpcId: Output<String>? = null) : ConvertibleToJava<VpcEndpointArgs>

Provides a VPC Endpoint resource.

NOTE on VPC Endpoints and VPC Endpoint Associations: The provider provides both standalone VPC Endpoint Associations for Route Tables - (an association between a VPC endpoint and a single route_table_id), Security Groups - (an association between a VPC endpoint and a single security_group_id), and Subnets - (an association between a VPC endpoint and a single subnet_id) and a VPC Endpoint resource with route_table_ids and subnet_ids attributes. Do not use the same resource ID in both a VPC Endpoint resource and a VPC Endpoint Association resource. Doing so will cause a conflict of associations and will overwrite the association.

Example Usage

Basic

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const s3 = new aws.ec2.VpcEndpoint("s3", {
vpcId: main.id,
serviceName: "com.amazonaws.us-west-2.s3",
});
import pulumi
import pulumi_aws as aws
s3 = aws.ec2.VpcEndpoint("s3",
vpc_id=main["id"],
service_name="com.amazonaws.us-west-2.s3")
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var s3 = new Aws.Ec2.VpcEndpoint("s3", new()
{
VpcId = main.Id,
ServiceName = "com.amazonaws.us-west-2.s3",
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2.NewVpcEndpoint(ctx, "s3", &ec2.VpcEndpointArgs{
VpcId: pulumi.Any(main.Id),
ServiceName: pulumi.String("com.amazonaws.us-west-2.s3"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2.VpcEndpoint;
import com.pulumi.aws.ec2.VpcEndpointArgs;
import java.util.List;
import java.util.ArrayList;
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 s3 = new VpcEndpoint("s3", VpcEndpointArgs.builder()
.vpcId(main.id())
.serviceName("com.amazonaws.us-west-2.s3")
.build());
}
}
resources:
s3:
type: aws:ec2:VpcEndpoint
properties:
vpcId: ${main.id}
serviceName: com.amazonaws.us-west-2.s3

Basic w/ Tags

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const s3 = new aws.ec2.VpcEndpoint("s3", {
vpcId: main.id,
serviceName: "com.amazonaws.us-west-2.s3",
tags: {
Environment: "test",
},
});
import pulumi
import pulumi_aws as aws
s3 = aws.ec2.VpcEndpoint("s3",
vpc_id=main["id"],
service_name="com.amazonaws.us-west-2.s3",
tags={
"Environment": "test",
})
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var s3 = new Aws.Ec2.VpcEndpoint("s3", new()
{
VpcId = main.Id,
ServiceName = "com.amazonaws.us-west-2.s3",
Tags =
{
{ "Environment", "test" },
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2.NewVpcEndpoint(ctx, "s3", &ec2.VpcEndpointArgs{
VpcId: pulumi.Any(main.Id),
ServiceName: pulumi.String("com.amazonaws.us-west-2.s3"),
Tags: pulumi.StringMap{
"Environment": pulumi.String("test"),
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2.VpcEndpoint;
import com.pulumi.aws.ec2.VpcEndpointArgs;
import java.util.List;
import java.util.ArrayList;
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 s3 = new VpcEndpoint("s3", VpcEndpointArgs.builder()
.vpcId(main.id())
.serviceName("com.amazonaws.us-west-2.s3")
.tags(Map.of("Environment", "test"))
.build());
}
}
resources:
s3:
type: aws:ec2:VpcEndpoint
properties:
vpcId: ${main.id}
serviceName: com.amazonaws.us-west-2.s3
tags:
Environment: test

Interface Endpoint Type

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const ec2 = new aws.ec2.VpcEndpoint("ec2", {
vpcId: main.id,
serviceName: "com.amazonaws.us-west-2.ec2",
vpcEndpointType: "Interface",
securityGroupIds: [sg1&#46;id],
privateDnsEnabled: true,
});
import pulumi
import pulumi_aws as aws
ec2 = aws.ec2.VpcEndpoint("ec2",
vpc_id=main["id"],
service_name="com.amazonaws.us-west-2.ec2",
vpc_endpoint_type="Interface",
security_group_ids=[sg1["id"]],
private_dns_enabled=True)
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var ec2 = new Aws.Ec2.VpcEndpoint("ec2", new()
{
VpcId = main.Id,
ServiceName = "com.amazonaws.us-west-2.ec2",
VpcEndpointType = "Interface",
SecurityGroupIds = new[]
{
sg1.Id,
},
PrivateDnsEnabled = true,
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2.NewVpcEndpoint(ctx, "ec2", &ec2.VpcEndpointArgs{
VpcId: pulumi.Any(main.Id),
ServiceName: pulumi.String("com.amazonaws.us-west-2.ec2"),
VpcEndpointType: pulumi.String("Interface"),
SecurityGroupIds: pulumi.StringArray{
sg1.Id,
},
PrivateDnsEnabled: pulumi.Bool(true),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2.VpcEndpoint;
import com.pulumi.aws.ec2.VpcEndpointArgs;
import java.util.List;
import java.util.ArrayList;
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 ec2 = new VpcEndpoint("ec2", VpcEndpointArgs.builder()
.vpcId(main.id())
.serviceName("com.amazonaws.us-west-2.ec2")
.vpcEndpointType("Interface")
.securityGroupIds(sg1.id())
.privateDnsEnabled(true)
.build());
}
}
resources:
ec2:
type: aws:ec2:VpcEndpoint
properties:
vpcId: ${main.id}
serviceName: com.amazonaws.us-west-2.ec2
vpcEndpointType: Interface
securityGroupIds:
- ${sg1.id}
privateDnsEnabled: true

Interface Endpoint Type with User-Defined IP Address

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const ec2 = new aws.ec2.VpcEndpoint("ec2", {
vpcId: example.id,
serviceName: "com.amazonaws.us-west-2.ec2",
vpcEndpointType: "Interface",
subnetConfigurations: [
{
ipv4: "10.0.1.10",
subnetId: example1.id,
},
{
ipv4: "10.0.2.10",
subnetId: example2.id,
},
],
subnetIds: [
example1.id,
example2.id,
],
});
import pulumi
import pulumi_aws as aws
ec2 = aws.ec2.VpcEndpoint("ec2",
vpc_id=example["id"],
service_name="com.amazonaws.us-west-2.ec2",
vpc_endpoint_type="Interface",
subnet_configurations=[
{
"ipv4": "10.0.1.10",
"subnet_id": example1["id"],
},
{
"ipv4": "10.0.2.10",
"subnet_id": example2["id"],
},
],
subnet_ids=[
example1["id"],
example2["id"],
])
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var ec2 = new Aws.Ec2.VpcEndpoint("ec2", new()
{
VpcId = example.Id,
ServiceName = "com.amazonaws.us-west-2.ec2",
VpcEndpointType = "Interface",
SubnetConfigurations = new[]
{
new Aws.Ec2.Inputs.VpcEndpointSubnetConfigurationArgs
{
Ipv4 = "10.0.1.10",
SubnetId = example1.Id,
},
new Aws.Ec2.Inputs.VpcEndpointSubnetConfigurationArgs
{
Ipv4 = "10.0.2.10",
SubnetId = example2.Id,
},
},
SubnetIds = new[]
{
example1.Id,
example2.Id,
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2.NewVpcEndpoint(ctx, "ec2", &ec2.VpcEndpointArgs{
VpcId: pulumi.Any(example.Id),
ServiceName: pulumi.String("com.amazonaws.us-west-2.ec2"),
VpcEndpointType: pulumi.String("Interface"),
SubnetConfigurations: ec2.VpcEndpointSubnetConfigurationArray{
&ec2.VpcEndpointSubnetConfigurationArgs{
Ipv4: pulumi.String("10.0.1.10"),
SubnetId: pulumi.Any(example1.Id),
},
&ec2.VpcEndpointSubnetConfigurationArgs{
Ipv4: pulumi.String("10.0.2.10"),
SubnetId: pulumi.Any(example2.Id),
},
},
SubnetIds: pulumi.StringArray{
example1.Id,
example2.Id,
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2.VpcEndpoint;
import com.pulumi.aws.ec2.VpcEndpointArgs;
import com.pulumi.aws.ec2.inputs.VpcEndpointSubnetConfigurationArgs;
import java.util.List;
import java.util.ArrayList;
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 ec2 = new VpcEndpoint("ec2", VpcEndpointArgs.builder()
.vpcId(example.id())
.serviceName("com.amazonaws.us-west-2.ec2")
.vpcEndpointType("Interface")
.subnetConfigurations(
VpcEndpointSubnetConfigurationArgs.builder()
.ipv4("10.0.1.10")
.subnetId(example1.id())
.build(),
VpcEndpointSubnetConfigurationArgs.builder()
.ipv4("10.0.2.10")
.subnetId(example2.id())
.build())
.subnetIds(
example1.id(),
example2.id())
.build());
}
}
resources:
ec2:
type: aws:ec2:VpcEndpoint
properties:
vpcId: ${example.id}
serviceName: com.amazonaws.us-west-2.ec2
vpcEndpointType: Interface
subnetConfigurations:
- ipv4: 10.0.1.10
subnetId: ${example1.id}
- ipv4: 10.0.2.10
subnetId: ${example2.id}
subnetIds:
- ${example1.id}
- ${example2.id}

Gateway Load Balancer Endpoint Type

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const current = aws.getCallerIdentity({});
const example = new aws.ec2.VpcEndpointService("example", {
acceptanceRequired: false,
allowedPrincipals: [current&#46;then(current => current&#46;arn)],
gatewayLoadBalancerArns: [exampleAwsLb&#46;arn],
});
const exampleVpcEndpoint = new aws.ec2.VpcEndpoint("example", {
serviceName: example.serviceName,
subnetIds: [exampleAwsSubnet&#46;id],
vpcEndpointType: example.serviceType,
vpcId: exampleAwsVpc.id,
});
import pulumi
import pulumi_aws as aws
current = aws.get_caller_identity()
example = aws.ec2.VpcEndpointService("example",
acceptance_required=False,
allowed_principals=[current&#46;arn],
gateway_load_balancer_arns=[example_aws_lb["arn"]])
example_vpc_endpoint = aws.ec2.VpcEndpoint("example",
service_name=example.service_name,
subnet_ids=[example_aws_subnet["id"]],
vpc_endpoint_type=example.service_type,
vpc_id=example_aws_vpc["id"])
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var current = Aws.GetCallerIdentity.Invoke();
var example = new Aws.Ec2.VpcEndpointService("example", new()
{
AcceptanceRequired = false,
AllowedPrincipals = new[]
{
current.Apply(getCallerIdentityResult => getCallerIdentityResult.Arn),
},
GatewayLoadBalancerArns = new[]
{
exampleAwsLb.Arn,
},
});
var exampleVpcEndpoint = new Aws.Ec2.VpcEndpoint("example", new()
{
ServiceName = example.ServiceName,
SubnetIds = new[]
{
exampleAwsSubnet.Id,
},
VpcEndpointType = example.ServiceType,
VpcId = exampleAwsVpc.Id,
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws"
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
current, err := aws.GetCallerIdentity(ctx, &aws.GetCallerIdentityArgs{}, nil)
if err != nil {
return err
}
example, err := ec2.NewVpcEndpointService(ctx, "example", &ec2.VpcEndpointServiceArgs{
AcceptanceRequired: pulumi.Bool(false),
AllowedPrincipals: pulumi.StringArray{
pulumi.String(current.Arn),
},
GatewayLoadBalancerArns: pulumi.StringArray{
exampleAwsLb.Arn,
},
})
if err != nil {
return err
}
_, err = ec2.NewVpcEndpoint(ctx, "example", &ec2.VpcEndpointArgs{
ServiceName: example.ServiceName,
SubnetIds: pulumi.StringArray{
exampleAwsSubnet.Id,
},
VpcEndpointType: example.ServiceType,
VpcId: pulumi.Any(exampleAwsVpc.Id),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.AwsFunctions;
import com.pulumi.aws.inputs.GetCallerIdentityArgs;
import com.pulumi.aws.ec2.VpcEndpointService;
import com.pulumi.aws.ec2.VpcEndpointServiceArgs;
import com.pulumi.aws.ec2.VpcEndpoint;
import com.pulumi.aws.ec2.VpcEndpointArgs;
import java.util.List;
import java.util.ArrayList;
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) {
final var current = AwsFunctions.getCallerIdentity();
var example = new VpcEndpointService("example", VpcEndpointServiceArgs.builder()
.acceptanceRequired(false)
.allowedPrincipals(current.applyValue(getCallerIdentityResult -> getCallerIdentityResult.arn()))
.gatewayLoadBalancerArns(exampleAwsLb.arn())
.build());
var exampleVpcEndpoint = new VpcEndpoint("exampleVpcEndpoint", VpcEndpointArgs.builder()
.serviceName(example.serviceName())
.subnetIds(exampleAwsSubnet.id())
.vpcEndpointType(example.serviceType())
.vpcId(exampleAwsVpc.id())
.build());
}
}
resources:
example:
type: aws:ec2:VpcEndpointService
properties:
acceptanceRequired: false
allowedPrincipals:
- ${current.arn}
gatewayLoadBalancerArns:
- ${exampleAwsLb.arn}
exampleVpcEndpoint:
type: aws:ec2:VpcEndpoint
name: example
properties:
serviceName: ${example.serviceName}
subnetIds:
- ${exampleAwsSubnet.id}
vpcEndpointType: ${example.serviceType}
vpcId: ${exampleAwsVpc.id}
variables:
current:
fn::invoke:
function: aws:getCallerIdentity
arguments: {}

VPC Lattice Resource Configuration Endpoint Type

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.ec2.VpcEndpoint("example", {
resourceConfigurationArn: exampleAwsVpclatticeResourceConfiguration.arn,
subnetIds: [exampleAwsSubnet&#46;id],
vpcEndpointType: "Resource",
vpcId: exampleAwsVpc.id,
});
import pulumi
import pulumi_aws as aws
example = aws.ec2.VpcEndpoint("example",
resource_configuration_arn=example_aws_vpclattice_resource_configuration["arn"],
subnet_ids=[example_aws_subnet["id"]],
vpc_endpoint_type="Resource",
vpc_id=example_aws_vpc["id"])
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.Ec2.VpcEndpoint("example", new()
{
ResourceConfigurationArn = exampleAwsVpclatticeResourceConfiguration.Arn,
SubnetIds = new[]
{
exampleAwsSubnet.Id,
},
VpcEndpointType = "Resource",
VpcId = exampleAwsVpc.Id,
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2.NewVpcEndpoint(ctx, "example", &ec2.VpcEndpointArgs{
ResourceConfigurationArn: pulumi.Any(exampleAwsVpclatticeResourceConfiguration.Arn),
SubnetIds: pulumi.StringArray{
exampleAwsSubnet.Id,
},
VpcEndpointType: pulumi.String("Resource"),
VpcId: pulumi.Any(exampleAwsVpc.Id),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2.VpcEndpoint;
import com.pulumi.aws.ec2.VpcEndpointArgs;
import java.util.List;
import java.util.ArrayList;
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 VpcEndpoint("example", VpcEndpointArgs.builder()
.resourceConfigurationArn(exampleAwsVpclatticeResourceConfiguration.arn())
.subnetIds(exampleAwsSubnet.id())
.vpcEndpointType("Resource")
.vpcId(exampleAwsVpc.id())
.build());
}
}
resources:
example:
type: aws:ec2:VpcEndpoint
properties:
resourceConfigurationArn: ${exampleAwsVpclatticeResourceConfiguration.arn}
subnetIds:
- ${exampleAwsSubnet.id}
vpcEndpointType: Resource
vpcId: ${exampleAwsVpc.id}

VPC Lattice Service Network Endpoint Type

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.ec2.VpcEndpoint("example", {
serviceNetworkArn: exampleAwsVpclatticeServiceNetwork.arn,
subnetIds: [exampleAwsSubnet&#46;id],
vpcEndpointType: "ServiceNetwork",
vpcId: exampleAwsVpc.id,
});
import pulumi
import pulumi_aws as aws
example = aws.ec2.VpcEndpoint("example",
service_network_arn=example_aws_vpclattice_service_network["arn"],
subnet_ids=[example_aws_subnet["id"]],
vpc_endpoint_type="ServiceNetwork",
vpc_id=example_aws_vpc["id"])
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.Ec2.VpcEndpoint("example", new()
{
ServiceNetworkArn = exampleAwsVpclatticeServiceNetwork.Arn,
SubnetIds = new[]
{
exampleAwsSubnet.Id,
},
VpcEndpointType = "ServiceNetwork",
VpcId = exampleAwsVpc.Id,
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2.NewVpcEndpoint(ctx, "example", &ec2.VpcEndpointArgs{
ServiceNetworkArn: pulumi.Any(exampleAwsVpclatticeServiceNetwork.Arn),
SubnetIds: pulumi.StringArray{
exampleAwsSubnet.Id,
},
VpcEndpointType: pulumi.String("ServiceNetwork"),
VpcId: pulumi.Any(exampleAwsVpc.Id),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2.VpcEndpoint;
import com.pulumi.aws.ec2.VpcEndpointArgs;
import java.util.List;
import java.util.ArrayList;
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 VpcEndpoint("example", VpcEndpointArgs.builder()
.serviceNetworkArn(exampleAwsVpclatticeServiceNetwork.arn())
.subnetIds(exampleAwsSubnet.id())
.vpcEndpointType("ServiceNetwork")
.vpcId(exampleAwsVpc.id())
.build());
}
}
resources:
example:
type: aws:ec2:VpcEndpoint
properties:
serviceNetworkArn: ${exampleAwsVpclatticeServiceNetwork.arn}
subnetIds:
- ${exampleAwsSubnet.id}
vpcEndpointType: ServiceNetwork
vpcId: ${exampleAwsVpc.id}

Import

Using pulumi import, import VPC Endpoints using the VPC endpoint id. For example:

$ pulumi import aws:ec2/vpcEndpoint:VpcEndpoint endpoint1 vpce-3ecf2a57

Constructors

Link copied to clipboard
constructor(autoAccept: Output<Boolean>? = null, dnsOptions: Output<VpcEndpointDnsOptionsArgs>? = null, ipAddressType: Output<String>? = null, policy: Output<String>? = null, privateDnsEnabled: Output<Boolean>? = null, resourceConfigurationArn: Output<String>? = null, routeTableIds: Output<List<String>>? = null, securityGroupIds: Output<List<String>>? = null, serviceName: Output<String>? = null, serviceNetworkArn: Output<String>? = null, serviceRegion: Output<String>? = null, subnetConfigurations: Output<List<VpcEndpointSubnetConfigurationArgs>>? = null, subnetIds: Output<List<String>>? = null, tags: Output<Map<String, String>>? = null, vpcEndpointType: Output<String>? = null, vpcId: Output<String>? = null)

Properties

Link copied to clipboard
val autoAccept: Output<Boolean>? = null

Accept the VPC endpoint (the VPC endpoint and service need to be in the same AWS account).

Link copied to clipboard

The DNS options for the endpoint. See dns_options below.

Link copied to clipboard
val ipAddressType: Output<String>? = null

The IP address type for the endpoint. Valid values are ipv4, dualstack, and ipv6.

Link copied to clipboard
val policy: Output<String>? = null

A policy to attach to the endpoint that controls access to the service. This is a JSON formatted string. Defaults to full access. All Gateway and some Interface endpoints support policies - see the relevant AWS documentation for more details.

Link copied to clipboard
val privateDnsEnabled: Output<Boolean>? = null

Whether or not to associate a private hosted zone with the specified VPC. Applicable for endpoints of type Interface. Most users will want this enabled to allow services within the VPC to automatically use the endpoint. Defaults to false.

Link copied to clipboard
val resourceConfigurationArn: Output<String>? = null

The ARN of a Resource Configuration to connect this VPC Endpoint to. Exactly one of resource_configuration_arn, service_name or service_network_arn is required.

Link copied to clipboard
val routeTableIds: Output<List<String>>? = null

One or more route table IDs. Applicable for endpoints of type Gateway.

Link copied to clipboard
val securityGroupIds: Output<List<String>>? = null

The ID of one or more security groups to associate with the network interface. Applicable for endpoints of type Interface. If no security groups are specified, the VPC's default security group is associated with the endpoint.

Link copied to clipboard
val serviceName: Output<String>? = null

The service name. For AWS services the service name is usually in the form com.amazonaws.<region>.<service> (the SageMaker AI Notebook service is an exception to this rule, the service name is in the form aws.sagemaker.<region>.notebook). Exactly one of resource_configuration_arn, service_name or service_network_arn is required.

Link copied to clipboard
val serviceNetworkArn: Output<String>? = null

The ARN of a Service Network to connect this VPC Endpoint to. Exactly one of resource_configuration_arn, service_name or service_network_arn is required.

Link copied to clipboard
val serviceRegion: Output<String>? = null

The AWS region of the VPC Endpoint Service. If specified, the VPC endpoint will connect to the service in the provided region. Applicable for endpoints of type Interface.

Link copied to clipboard

Subnet configuration for the endpoint, used to select specific IPv4 and/or IPv6 addresses to the endpoint. See subnet_configuration below.

Link copied to clipboard
val subnetIds: Output<List<String>>? = null

The ID of one or more subnets in which to create a network interface for the endpoint. Applicable for endpoints of type GatewayLoadBalancer and Interface. Interface type endpoints cannot function without being assigned to a subnet.

Link copied to clipboard
val tags: Output<Map<String, String>>? = null

A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Link copied to clipboard
val vpcEndpointType: Output<String>? = null

The VPC endpoint type, Gateway, GatewayLoadBalancer,Interface, Resource or ServiceNetwork. Defaults to Gateway.

Link copied to clipboard
val vpcId: Output<String>? = null

The ID of the VPC in which the endpoint will be used.

Functions

Link copied to clipboard
open override fun toJava(): VpcEndpointArgs