UNPKG

@pulumi/aws

Version:

A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.

108 lines 5.36 kB
"use strict"; // *** WARNING: this file was generated by pulumi-language-nodejs. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.VpcEndpointAssociation = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Manages a firewall endpoint for an AWS Network Firewall firewall. * * Use `aws.networkfirewall.VpcEndpointAssociation` to establish new firewall endpoints in any Availability Zone where the firewall is already being used. The first use of a firewall in an Availability Zone must be defined by `aws.networkfirewall.Firewall` resource and `subnetMapping` argument. * * ## Example Usage * * ### Basic Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.networkfirewall.VpcEndpointAssociation("example", { * firewallArn: exampleAwsNetworkfirewallFirewall.arn, * vpcId: exampleAwsVpc.id, * subnetMapping: { * subnetId: exampleTwo.id, * }, * tags: { * Name: "example endpoint", * }, * }); * ``` * * ## Import * * Using `pulumi import`, import Network Firewall VPC Endpoint Association using the `vpc_endpoint_association_arn`. For example: * * ```sh * $ pulumi import aws:networkfirewall/vpcEndpointAssociation:VpcEndpointAssociation example arn:aws:network-firewall:us-west-1:123456789012:vpc-endpoint-association/example * ``` */ class VpcEndpointAssociation extends pulumi.CustomResource { /** * Get an existing VpcEndpointAssociation 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, id, state, opts) { return new VpcEndpointAssociation(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of VpcEndpointAssociation. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj) { if (obj === undefined || obj === null) { return false; } return obj['__pulumiType'] === VpcEndpointAssociation.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["description"] = state ? state.description : undefined; resourceInputs["firewallArn"] = state ? state.firewallArn : undefined; resourceInputs["region"] = state ? state.region : undefined; resourceInputs["subnetMapping"] = state ? state.subnetMapping : undefined; resourceInputs["tags"] = state ? state.tags : undefined; resourceInputs["tagsAll"] = state ? state.tagsAll : undefined; resourceInputs["timeouts"] = state ? state.timeouts : undefined; resourceInputs["vpcEndpointAssociationArn"] = state ? state.vpcEndpointAssociationArn : undefined; resourceInputs["vpcEndpointAssociationId"] = state ? state.vpcEndpointAssociationId : undefined; resourceInputs["vpcEndpointAssociationStatuses"] = state ? state.vpcEndpointAssociationStatuses : undefined; resourceInputs["vpcId"] = state ? state.vpcId : undefined; } else { const args = argsOrState; if ((!args || args.firewallArn === undefined) && !opts.urn) { throw new Error("Missing required property 'firewallArn'"); } if ((!args || args.vpcId === undefined) && !opts.urn) { throw new Error("Missing required property 'vpcId'"); } resourceInputs["description"] = args ? args.description : undefined; resourceInputs["firewallArn"] = args ? args.firewallArn : undefined; resourceInputs["region"] = args ? args.region : undefined; resourceInputs["subnetMapping"] = args ? args.subnetMapping : undefined; resourceInputs["tags"] = args ? args.tags : undefined; resourceInputs["timeouts"] = args ? args.timeouts : undefined; resourceInputs["vpcId"] = args ? args.vpcId : undefined; resourceInputs["tagsAll"] = undefined /*out*/; resourceInputs["vpcEndpointAssociationArn"] = undefined /*out*/; resourceInputs["vpcEndpointAssociationId"] = undefined /*out*/; resourceInputs["vpcEndpointAssociationStatuses"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(VpcEndpointAssociation.__pulumiType, name, resourceInputs, opts); } } exports.VpcEndpointAssociation = VpcEndpointAssociation; /** @internal */ VpcEndpointAssociation.__pulumiType = 'aws:networkfirewall/vpcEndpointAssociation:VpcEndpointAssociation'; //# sourceMappingURL=vpcEndpointAssociation.js.map