AWS Native is in preview. AWS Classic is fully supported.
aws-native.ec2.VpcEndpoint
Explore with Pulumi AI
AWS Native is in preview. AWS Classic is fully supported.
Specifies a VPC endpoint. A VPC endpoint provides a private connection between your VPC and an endpoint service. You can use an endpoint service provided by AWS , an AWS Marketplace Partner, or another AWS accounts in your organization. For more information, see the AWS PrivateLink User Guide .
An endpoint of type Interface
establishes connections between the subnets in your VPC and an AWS service , your own service, or a service hosted by another AWS account . With an interface VPC endpoint, you specify the subnets in which to create the endpoint and the security groups to associate with the endpoint network interfaces.
An endpoint of type gateway
serves as a target for a route in your route table for traffic destined for Amazon S3 or DynamoDB . You can specify an endpoint policy for the endpoint, which controls access to the service from your VPC. You can also specify the VPC route tables that use the endpoint. For more information about connectivity to Amazon S3 , see Why can’t I connect to an S3 bucket using a gateway VPC endpoint?
An endpoint of type GatewayLoadBalancer
provides private connectivity between your VPC and virtual appliances from a service provider.
Create VpcEndpoint Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new VpcEndpoint(name: string, args: VpcEndpointArgs, opts?: CustomResourceOptions);
@overload
def VpcEndpoint(resource_name: str,
args: VpcEndpointArgs,
opts: Optional[ResourceOptions] = None)
@overload
def VpcEndpoint(resource_name: str,
opts: Optional[ResourceOptions] = None,
service_name: Optional[str] = None,
vpc_id: Optional[str] = None,
policy_document: Optional[Any] = None,
private_dns_enabled: Optional[bool] = None,
route_table_ids: Optional[Sequence[str]] = None,
security_group_ids: Optional[Sequence[str]] = None,
subnet_ids: Optional[Sequence[str]] = None,
vpc_endpoint_type: Optional[VpcEndpointType] = None)
func NewVpcEndpoint(ctx *Context, name string, args VpcEndpointArgs, opts ...ResourceOption) (*VpcEndpoint, error)
public VpcEndpoint(string name, VpcEndpointArgs args, CustomResourceOptions? opts = null)
public VpcEndpoint(String name, VpcEndpointArgs args)
public VpcEndpoint(String name, VpcEndpointArgs args, CustomResourceOptions options)
type: aws-native:ec2:VpcEndpoint
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args VpcEndpointArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args VpcEndpointArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args VpcEndpointArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args VpcEndpointArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args VpcEndpointArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
VpcEndpoint Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The VpcEndpoint resource accepts the following input properties:
- Service
Name string - The name of the endpoint service.
- Vpc
Id string - The ID of the VPC.
- Policy
Document object An endpoint policy, which controls access to the service from the VPC. The default endpoint policy allows full access to the service. Endpoint policies are supported only for gateway and interface endpoints. For CloudFormation templates in YAML, you can provide the policy in JSON or YAML format. CFNlong converts YAML policies to JSON format before calling the API to create or modify the VPC endpoint.
Search the CloudFormation User Guide for
AWS::EC2::VPCEndpoint
for more information about the expected schema for this property.- Private
Dns boolEnabled - Indicate whether to associate a private hosted zone with the specified VPC. The private hosted zone contains a record set for the default public DNS name for the service for the Region (for example,
kinesis.us-east-1.amazonaws.com
), which resolves to the private IP addresses of the endpoint network interfaces in the VPC. This enables you to make requests to the default public DNS name for the service instead of the public DNS names that are automatically generated by the VPC endpoint service. To use a private hosted zone, you must set the following VPC attributes totrue
:enableDnsHostnames
andenableDnsSupport
. This property is supported only for interface endpoints. Default:false
- Route
Table List<string>Ids - The IDs of the route tables. Routing is supported only for gateway endpoints.
- Security
Group List<string>Ids - The IDs of the security groups to associate with the endpoint network interfaces. If this parameter is not specified, we use the default security group for the VPC. Security groups are supported only for interface endpoints.
- Subnet
Ids List<string> - The IDs of the subnets in which to create endpoint network interfaces. You must specify this property for an interface endpoint or a Gateway Load Balancer endpoint. You can't specify this property for a gateway endpoint. For a Gateway Load Balancer endpoint, you can specify only one subnet.
- Vpc
Endpoint Pulumi.Type Aws Native. Ec2. Vpc Endpoint Type - The type of endpoint. Default: Gateway
- Service
Name string - The name of the endpoint service.
- Vpc
Id string - The ID of the VPC.
- Policy
Document interface{} An endpoint policy, which controls access to the service from the VPC. The default endpoint policy allows full access to the service. Endpoint policies are supported only for gateway and interface endpoints. For CloudFormation templates in YAML, you can provide the policy in JSON or YAML format. CFNlong converts YAML policies to JSON format before calling the API to create or modify the VPC endpoint.
Search the CloudFormation User Guide for
AWS::EC2::VPCEndpoint
for more information about the expected schema for this property.- Private
Dns boolEnabled - Indicate whether to associate a private hosted zone with the specified VPC. The private hosted zone contains a record set for the default public DNS name for the service for the Region (for example,
kinesis.us-east-1.amazonaws.com
), which resolves to the private IP addresses of the endpoint network interfaces in the VPC. This enables you to make requests to the default public DNS name for the service instead of the public DNS names that are automatically generated by the VPC endpoint service. To use a private hosted zone, you must set the following VPC attributes totrue
:enableDnsHostnames
andenableDnsSupport
. This property is supported only for interface endpoints. Default:false
- Route
Table []stringIds - The IDs of the route tables. Routing is supported only for gateway endpoints.
- Security
Group []stringIds - The IDs of the security groups to associate with the endpoint network interfaces. If this parameter is not specified, we use the default security group for the VPC. Security groups are supported only for interface endpoints.
- Subnet
Ids []string - The IDs of the subnets in which to create endpoint network interfaces. You must specify this property for an interface endpoint or a Gateway Load Balancer endpoint. You can't specify this property for a gateway endpoint. For a Gateway Load Balancer endpoint, you can specify only one subnet.
- Vpc
Endpoint VpcType Endpoint Type - The type of endpoint. Default: Gateway
- service
Name String - The name of the endpoint service.
- vpc
Id String - The ID of the VPC.
- policy
Document Object An endpoint policy, which controls access to the service from the VPC. The default endpoint policy allows full access to the service. Endpoint policies are supported only for gateway and interface endpoints. For CloudFormation templates in YAML, you can provide the policy in JSON or YAML format. CFNlong converts YAML policies to JSON format before calling the API to create or modify the VPC endpoint.
Search the CloudFormation User Guide for
AWS::EC2::VPCEndpoint
for more information about the expected schema for this property.- private
Dns BooleanEnabled - Indicate whether to associate a private hosted zone with the specified VPC. The private hosted zone contains a record set for the default public DNS name for the service for the Region (for example,
kinesis.us-east-1.amazonaws.com
), which resolves to the private IP addresses of the endpoint network interfaces in the VPC. This enables you to make requests to the default public DNS name for the service instead of the public DNS names that are automatically generated by the VPC endpoint service. To use a private hosted zone, you must set the following VPC attributes totrue
:enableDnsHostnames
andenableDnsSupport
. This property is supported only for interface endpoints. Default:false
- route
Table List<String>Ids - The IDs of the route tables. Routing is supported only for gateway endpoints.
- security
Group List<String>Ids - The IDs of the security groups to associate with the endpoint network interfaces. If this parameter is not specified, we use the default security group for the VPC. Security groups are supported only for interface endpoints.
- subnet
Ids List<String> - The IDs of the subnets in which to create endpoint network interfaces. You must specify this property for an interface endpoint or a Gateway Load Balancer endpoint. You can't specify this property for a gateway endpoint. For a Gateway Load Balancer endpoint, you can specify only one subnet.
- vpc
Endpoint VpcType Endpoint Type - The type of endpoint. Default: Gateway
- service
Name string - The name of the endpoint service.
- vpc
Id string - The ID of the VPC.
- policy
Document any An endpoint policy, which controls access to the service from the VPC. The default endpoint policy allows full access to the service. Endpoint policies are supported only for gateway and interface endpoints. For CloudFormation templates in YAML, you can provide the policy in JSON or YAML format. CFNlong converts YAML policies to JSON format before calling the API to create or modify the VPC endpoint.
Search the CloudFormation User Guide for
AWS::EC2::VPCEndpoint
for more information about the expected schema for this property.- private
Dns booleanEnabled - Indicate whether to associate a private hosted zone with the specified VPC. The private hosted zone contains a record set for the default public DNS name for the service for the Region (for example,
kinesis.us-east-1.amazonaws.com
), which resolves to the private IP addresses of the endpoint network interfaces in the VPC. This enables you to make requests to the default public DNS name for the service instead of the public DNS names that are automatically generated by the VPC endpoint service. To use a private hosted zone, you must set the following VPC attributes totrue
:enableDnsHostnames
andenableDnsSupport
. This property is supported only for interface endpoints. Default:false
- route
Table string[]Ids - The IDs of the route tables. Routing is supported only for gateway endpoints.
- security
Group string[]Ids - The IDs of the security groups to associate with the endpoint network interfaces. If this parameter is not specified, we use the default security group for the VPC. Security groups are supported only for interface endpoints.
- subnet
Ids string[] - The IDs of the subnets in which to create endpoint network interfaces. You must specify this property for an interface endpoint or a Gateway Load Balancer endpoint. You can't specify this property for a gateway endpoint. For a Gateway Load Balancer endpoint, you can specify only one subnet.
- vpc
Endpoint VpcType Endpoint Type - The type of endpoint. Default: Gateway
- service_
name str - The name of the endpoint service.
- vpc_
id str - The ID of the VPC.
- policy_
document Any An endpoint policy, which controls access to the service from the VPC. The default endpoint policy allows full access to the service. Endpoint policies are supported only for gateway and interface endpoints. For CloudFormation templates in YAML, you can provide the policy in JSON or YAML format. CFNlong converts YAML policies to JSON format before calling the API to create or modify the VPC endpoint.
Search the CloudFormation User Guide for
AWS::EC2::VPCEndpoint
for more information about the expected schema for this property.- private_
dns_ boolenabled - Indicate whether to associate a private hosted zone with the specified VPC. The private hosted zone contains a record set for the default public DNS name for the service for the Region (for example,
kinesis.us-east-1.amazonaws.com
), which resolves to the private IP addresses of the endpoint network interfaces in the VPC. This enables you to make requests to the default public DNS name for the service instead of the public DNS names that are automatically generated by the VPC endpoint service. To use a private hosted zone, you must set the following VPC attributes totrue
:enableDnsHostnames
andenableDnsSupport
. This property is supported only for interface endpoints. Default:false
- route_
table_ Sequence[str]ids - The IDs of the route tables. Routing is supported only for gateway endpoints.
- security_
group_ Sequence[str]ids - The IDs of the security groups to associate with the endpoint network interfaces. If this parameter is not specified, we use the default security group for the VPC. Security groups are supported only for interface endpoints.
- subnet_
ids Sequence[str] - The IDs of the subnets in which to create endpoint network interfaces. You must specify this property for an interface endpoint or a Gateway Load Balancer endpoint. You can't specify this property for a gateway endpoint. For a Gateway Load Balancer endpoint, you can specify only one subnet.
- vpc_
endpoint_ Vpctype Endpoint Type - The type of endpoint. Default: Gateway
- service
Name String - The name of the endpoint service.
- vpc
Id String - The ID of the VPC.
- policy
Document Any An endpoint policy, which controls access to the service from the VPC. The default endpoint policy allows full access to the service. Endpoint policies are supported only for gateway and interface endpoints. For CloudFormation templates in YAML, you can provide the policy in JSON or YAML format. CFNlong converts YAML policies to JSON format before calling the API to create or modify the VPC endpoint.
Search the CloudFormation User Guide for
AWS::EC2::VPCEndpoint
for more information about the expected schema for this property.- private
Dns BooleanEnabled - Indicate whether to associate a private hosted zone with the specified VPC. The private hosted zone contains a record set for the default public DNS name for the service for the Region (for example,
kinesis.us-east-1.amazonaws.com
), which resolves to the private IP addresses of the endpoint network interfaces in the VPC. This enables you to make requests to the default public DNS name for the service instead of the public DNS names that are automatically generated by the VPC endpoint service. To use a private hosted zone, you must set the following VPC attributes totrue
:enableDnsHostnames
andenableDnsSupport
. This property is supported only for interface endpoints. Default:false
- route
Table List<String>Ids - The IDs of the route tables. Routing is supported only for gateway endpoints.
- security
Group List<String>Ids - The IDs of the security groups to associate with the endpoint network interfaces. If this parameter is not specified, we use the default security group for the VPC. Security groups are supported only for interface endpoints.
- subnet
Ids List<String> - The IDs of the subnets in which to create endpoint network interfaces. You must specify this property for an interface endpoint or a Gateway Load Balancer endpoint. You can't specify this property for a gateway endpoint. For a Gateway Load Balancer endpoint, you can specify only one subnet.
- vpc
Endpoint "Interface" | "Gateway" | "GatewayType Load Balancer" - The type of endpoint. Default: Gateway
Outputs
All input properties are implicitly available as output properties. Additionally, the VpcEndpoint resource produces the following output properties:
- Aws
Id string - The ID of the VPC endpoint.
- Creation
Timestamp string - The date and time the VPC endpoint was created. For example:
Fri Sep 28 23:34:36 UTC 2018.
- Dns
Entries List<string> (Interface endpoints) The DNS entries for the endpoint. Each entry is a combination of the hosted zone ID and the DNS name. The entries are ordered as follows: regional public DNS, zonal public DNS, private DNS, and wildcard DNS. This order is not enforced for AWS Marketplace services.
The following is an example. In the first entry, the hosted zone ID is Z1HUB23UULQXV and the DNS name is vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com.
["Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com", "Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3-us-east-1a.ec2.us-east-1.vpce.amazonaws.com", "Z1C12344VYDITB0:ec2.us-east-1.amazonaws.com"]
If you update the
PrivateDnsEnabled
orSubnetIds
properties, the DNS entries in the list will change.- Id string
- The provider-assigned unique ID for this managed resource.
- Network
Interface List<string>Ids - (Interface endpoints) The network interface IDs. If you update the
PrivateDnsEnabled
orSubnetIds
properties, the items in this list might change.
- Aws
Id string - The ID of the VPC endpoint.
- Creation
Timestamp string - The date and time the VPC endpoint was created. For example:
Fri Sep 28 23:34:36 UTC 2018.
- Dns
Entries []string (Interface endpoints) The DNS entries for the endpoint. Each entry is a combination of the hosted zone ID and the DNS name. The entries are ordered as follows: regional public DNS, zonal public DNS, private DNS, and wildcard DNS. This order is not enforced for AWS Marketplace services.
The following is an example. In the first entry, the hosted zone ID is Z1HUB23UULQXV and the DNS name is vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com.
["Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com", "Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3-us-east-1a.ec2.us-east-1.vpce.amazonaws.com", "Z1C12344VYDITB0:ec2.us-east-1.amazonaws.com"]
If you update the
PrivateDnsEnabled
orSubnetIds
properties, the DNS entries in the list will change.- Id string
- The provider-assigned unique ID for this managed resource.
- Network
Interface []stringIds - (Interface endpoints) The network interface IDs. If you update the
PrivateDnsEnabled
orSubnetIds
properties, the items in this list might change.
- aws
Id String - The ID of the VPC endpoint.
- creation
Timestamp String - The date and time the VPC endpoint was created. For example:
Fri Sep 28 23:34:36 UTC 2018.
- dns
Entries List<String> (Interface endpoints) The DNS entries for the endpoint. Each entry is a combination of the hosted zone ID and the DNS name. The entries are ordered as follows: regional public DNS, zonal public DNS, private DNS, and wildcard DNS. This order is not enforced for AWS Marketplace services.
The following is an example. In the first entry, the hosted zone ID is Z1HUB23UULQXV and the DNS name is vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com.
["Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com", "Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3-us-east-1a.ec2.us-east-1.vpce.amazonaws.com", "Z1C12344VYDITB0:ec2.us-east-1.amazonaws.com"]
If you update the
PrivateDnsEnabled
orSubnetIds
properties, the DNS entries in the list will change.- id String
- The provider-assigned unique ID for this managed resource.
- network
Interface List<String>Ids - (Interface endpoints) The network interface IDs. If you update the
PrivateDnsEnabled
orSubnetIds
properties, the items in this list might change.
- aws
Id string - The ID of the VPC endpoint.
- creation
Timestamp string - The date and time the VPC endpoint was created. For example:
Fri Sep 28 23:34:36 UTC 2018.
- dns
Entries string[] (Interface endpoints) The DNS entries for the endpoint. Each entry is a combination of the hosted zone ID and the DNS name. The entries are ordered as follows: regional public DNS, zonal public DNS, private DNS, and wildcard DNS. This order is not enforced for AWS Marketplace services.
The following is an example. In the first entry, the hosted zone ID is Z1HUB23UULQXV and the DNS name is vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com.
["Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com", "Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3-us-east-1a.ec2.us-east-1.vpce.amazonaws.com", "Z1C12344VYDITB0:ec2.us-east-1.amazonaws.com"]
If you update the
PrivateDnsEnabled
orSubnetIds
properties, the DNS entries in the list will change.- id string
- The provider-assigned unique ID for this managed resource.
- network
Interface string[]Ids - (Interface endpoints) The network interface IDs. If you update the
PrivateDnsEnabled
orSubnetIds
properties, the items in this list might change.
- aws_
id str - The ID of the VPC endpoint.
- creation_
timestamp str - The date and time the VPC endpoint was created. For example:
Fri Sep 28 23:34:36 UTC 2018.
- dns_
entries Sequence[str] (Interface endpoints) The DNS entries for the endpoint. Each entry is a combination of the hosted zone ID and the DNS name. The entries are ordered as follows: regional public DNS, zonal public DNS, private DNS, and wildcard DNS. This order is not enforced for AWS Marketplace services.
The following is an example. In the first entry, the hosted zone ID is Z1HUB23UULQXV and the DNS name is vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com.
["Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com", "Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3-us-east-1a.ec2.us-east-1.vpce.amazonaws.com", "Z1C12344VYDITB0:ec2.us-east-1.amazonaws.com"]
If you update the
PrivateDnsEnabled
orSubnetIds
properties, the DNS entries in the list will change.- id str
- The provider-assigned unique ID for this managed resource.
- network_
interface_ Sequence[str]ids - (Interface endpoints) The network interface IDs. If you update the
PrivateDnsEnabled
orSubnetIds
properties, the items in this list might change.
- aws
Id String - The ID of the VPC endpoint.
- creation
Timestamp String - The date and time the VPC endpoint was created. For example:
Fri Sep 28 23:34:36 UTC 2018.
- dns
Entries List<String> (Interface endpoints) The DNS entries for the endpoint. Each entry is a combination of the hosted zone ID and the DNS name. The entries are ordered as follows: regional public DNS, zonal public DNS, private DNS, and wildcard DNS. This order is not enforced for AWS Marketplace services.
The following is an example. In the first entry, the hosted zone ID is Z1HUB23UULQXV and the DNS name is vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com.
["Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3.ec2.us-east-1.vpce.amazonaws.com", "Z1HUB23UULQXV:vpce-01abc23456de78f9g-12abccd3-us-east-1a.ec2.us-east-1.vpce.amazonaws.com", "Z1C12344VYDITB0:ec2.us-east-1.amazonaws.com"]
If you update the
PrivateDnsEnabled
orSubnetIds
properties, the DNS entries in the list will change.- id String
- The provider-assigned unique ID for this managed resource.
- network
Interface List<String>Ids - (Interface endpoints) The network interface IDs. If you update the
PrivateDnsEnabled
orSubnetIds
properties, the items in this list might change.
Supporting Types
VpcEndpointType, VpcEndpointTypeArgs
- Interface
- Interface
- Gateway
- Gateway
- Gateway
Load Balancer - GatewayLoadBalancer
- Vpc
Endpoint Type Interface - Interface
- Vpc
Endpoint Type Gateway - Gateway
- Vpc
Endpoint Type Gateway Load Balancer - GatewayLoadBalancer
- Interface
- Interface
- Gateway
- Gateway
- Gateway
Load Balancer - GatewayLoadBalancer
- Interface
- Interface
- Gateway
- Gateway
- Gateway
Load Balancer - GatewayLoadBalancer
- INTERFACE
- Interface
- GATEWAY
- Gateway
- GATEWAY_LOAD_BALANCER
- GatewayLoadBalancer
- "Interface"
- Interface
- "Gateway"
- Gateway
- "Gateway
Load Balancer" - GatewayLoadBalancer
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
AWS Native is in preview. AWS Classic is fully supported.