Class VpcEndpointSubnetAssociation
Provides a resource to create an association between a VPC endpoint and a subnet.
NOTE on VPC Endpoints and VPC Endpoint Subnet Associations: This provider provides both a standalone VPC Endpoint Subnet Association (an association between a VPC endpoint and a single
subnet_id) and a VPC Endpoint resource with asubnet_idsattribute. Do not use the same subnet ID in both a VPC Endpoint resource and a VPC Endpoint Subnet Association resource. Doing so will cause a conflict of associations and will overwrite the association.
Example Usage
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var snEc2 = new Aws.Ec2.VpcEndpointSubnetAssociation("snEc2", new Aws.Ec2.VpcEndpointSubnetAssociationArgs
{
SubnetId = aws_subnet.Sn.Id,
VpcEndpointId = aws_vpc_endpoint.Ec2.Id,
});
}
}
Inherited Members
Namespace: Pulumi.Aws.Ec2
Assembly: Pulumi.Aws.dll
Syntax
public class VpcEndpointSubnetAssociation : CustomResource
Constructors
View SourceVpcEndpointSubnetAssociation(String, VpcEndpointSubnetAssociationArgs, CustomResourceOptions)
Create a VpcEndpointSubnetAssociation resource with the given unique name, arguments, and options.
Declaration
public VpcEndpointSubnetAssociation(string name, VpcEndpointSubnetAssociationArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| VpcEndpointSubnetAssociationArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceSubnetId
The ID of the subnet to be associated with the VPC endpoint.
Declaration
public Output<string> SubnetId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
VpcEndpointId
The ID of the VPC endpoint with which the subnet will be associated.
Declaration
public Output<string> VpcEndpointId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, VpcEndpointSubnetAssociationState, CustomResourceOptions)
Get an existing VpcEndpointSubnetAssociation resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static VpcEndpointSubnetAssociation Get(string name, Input<string> id, VpcEndpointSubnetAssociationState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| VpcEndpointSubnetAssociationState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| VpcEndpointSubnetAssociation |