@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
104 lines (103 loc) • 4.46 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* 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 `subnetId`) and a VPC Endpoint resource with a `subnetIds`
* attribute. 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
*
* Basic usage:
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const snEc2 = new aws.ec2.VpcEndpointSubnetAssociation("sn_ec2", {
* vpcEndpointId: ec2.id,
* subnetId: sn.id,
* });
* ```
*
* ## Import
*
* Using `pulumi import`, import VPC Endpoint Subnet Associations using `vpc_endpoint_id` together with `subnet_id`. For example:
*
* ```sh
* $ pulumi import aws:ec2/vpcEndpointSubnetAssociation:VpcEndpointSubnetAssociation example vpce-aaaaaaaa/subnet-bbbbbbbbbbbbbbbbb
* ```
*/
export declare class VpcEndpointSubnetAssociation extends pulumi.CustomResource {
/**
* Get an existing VpcEndpointSubnetAssociation resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: VpcEndpointSubnetAssociationState, opts?: pulumi.CustomResourceOptions): VpcEndpointSubnetAssociation;
/**
* Returns true if the given object is an instance of VpcEndpointSubnetAssociation. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is VpcEndpointSubnetAssociation;
/**
* Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
*/
readonly region: pulumi.Output<string>;
/**
* The ID of the subnet to be associated with the VPC endpoint.
*/
readonly subnetId: pulumi.Output<string>;
/**
* The ID of the VPC endpoint with which the subnet will be associated.
*/
readonly vpcEndpointId: pulumi.Output<string>;
/**
* Create a VpcEndpointSubnetAssociation resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args: VpcEndpointSubnetAssociationArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering VpcEndpointSubnetAssociation resources.
*/
export interface VpcEndpointSubnetAssociationState {
/**
* Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
*/
region?: pulumi.Input<string>;
/**
* The ID of the subnet to be associated with the VPC endpoint.
*/
subnetId?: pulumi.Input<string>;
/**
* The ID of the VPC endpoint with which the subnet will be associated.
*/
vpcEndpointId?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a VpcEndpointSubnetAssociation resource.
*/
export interface VpcEndpointSubnetAssociationArgs {
/**
* Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
*/
region?: pulumi.Input<string>;
/**
* The ID of the subnet to be associated with the VPC endpoint.
*/
subnetId: pulumi.Input<string>;
/**
* The ID of the VPC endpoint with which the subnet will be associated.
*/
vpcEndpointId: pulumi.Input<string>;
}