UNPKG

@pulumi/aws

Version:

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

264 lines (263 loc) • 12.2 kB
import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Provides an IPAM resource. * * ## Example Usage * * Basic usage: * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const current = aws.getRegion({}); * const main = new aws.ec2.VpcIpam("main", { * description: "My IPAM", * operatingRegions: [{ * regionName: current.then(current => current.region), * }], * tags: { * Test: "Main", * }, * }); * ``` * * Shared with multiple operating_regions: * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * import * as std from "@pulumi/std"; * * const current = aws.getRegion({}); * const config = new pulumi.Config(); * const ipamRegions = config.getObject<Array<any>>("ipamRegions") || [ * "us-east-1", * "us-west-2", * ]; * // ensure current provider region is an operating_regions entry * const allIpamRegions = std.concat({ * input: [ * [current.then(current => current.region)], * ipamRegions, * ], * }).then(invoke => std.distinct({ * input: invoke.result, * })).then(invoke => invoke.result); * const main = new aws.ec2.VpcIpam("main", { * operatingRegions: allIpamRegions.map((v, k) => ({key: k, value: v})).apply(entries => entries.map(entry => ({ * regionName: entry.value, * }))), * description: "multi region ipam", * }); * ``` * * ## Import * * Using `pulumi import`, import IPAMs using the IPAM `id`. For example: * * ```sh * $ pulumi import aws:ec2/vpcIpam:VpcIpam example ipam-0178368ad2146a492 * ``` */ export declare class VpcIpam extends pulumi.CustomResource { /** * Get an existing VpcIpam 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?: VpcIpamState, opts?: pulumi.CustomResourceOptions): VpcIpam; /** * Returns true if the given object is an instance of VpcIpam. 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 VpcIpam; /** * Amazon Resource Name (ARN) of IPAM */ readonly arn: pulumi.Output<string>; /** * Enables you to quickly delete an IPAM, private scopes, pools in private scopes, and any allocations in the pools in private scopes. */ readonly cascade: pulumi.Output<boolean | undefined>; /** * The IPAM's default resource discovery association ID. */ readonly defaultResourceDiscoveryAssociationId: pulumi.Output<string>; /** * The IPAM's default resource discovery ID. */ readonly defaultResourceDiscoveryId: pulumi.Output<string>; /** * A description for the IPAM. */ readonly description: pulumi.Output<string | undefined>; /** * Enable this option to use your own GUA ranges as private IPv6 addresses. Default: `false`. */ readonly enablePrivateGua: pulumi.Output<boolean | undefined>; /** * AWS account that is charged for active IP addresses managed in IPAM. Valid values are `ipam-owner` (default) and `resource-owner`. */ readonly meteredAccount: pulumi.Output<string>; /** * Determines which locales can be chosen when you create pools. Locale is the Region where you want to make an IPAM pool available for allocations. You can only create pools with locales that match the operating Regions of the IPAM. You can only create VPCs from a pool whose locale matches the VPC's Region. You specify a region using the regionName parameter. You **must** set your provider block region as an operating_region. */ readonly operatingRegions: pulumi.Output<outputs.ec2.VpcIpamOperatingRegion[]>; /** * The ID of the IPAM's private scope. A scope is a top-level container in IPAM. Each scope represents an IP-independent network. Scopes enable you to represent networks where you have overlapping IP space. When you create an IPAM, IPAM automatically creates two scopes: public and private. The private scope is intended for private IP space. The public scope is intended for all internet-routable IP space. */ readonly privateDefaultScopeId: pulumi.Output<string>; /** * The ID of the IPAM's public scope. A scope is a top-level container in IPAM. Each scope represents an IP-independent network. Scopes enable you to represent networks where you have overlapping IP space. When you create an IPAM, IPAM automatically creates two scopes: public and private. The private scope is intended for private * IP space. The public scope is intended for all internet-routable IP space. */ readonly publicDefaultScopeId: pulumi.Output<string>; /** * 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 number of scopes in the IPAM. */ readonly scopeCount: pulumi.Output<number>; /** * A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. */ readonly tags: pulumi.Output<{ [key: string]: string; } | undefined>; /** * A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. */ readonly tagsAll: pulumi.Output<{ [key: string]: string; }>; /** * specifies the IPAM tier. Valid options include `free` and `advanced`. Default is `advanced`. */ readonly tier: pulumi.Output<string | undefined>; /** * Create a VpcIpam 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: VpcIpamArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering VpcIpam resources. */ export interface VpcIpamState { /** * Amazon Resource Name (ARN) of IPAM */ arn?: pulumi.Input<string>; /** * Enables you to quickly delete an IPAM, private scopes, pools in private scopes, and any allocations in the pools in private scopes. */ cascade?: pulumi.Input<boolean>; /** * The IPAM's default resource discovery association ID. */ defaultResourceDiscoveryAssociationId?: pulumi.Input<string>; /** * The IPAM's default resource discovery ID. */ defaultResourceDiscoveryId?: pulumi.Input<string>; /** * A description for the IPAM. */ description?: pulumi.Input<string>; /** * Enable this option to use your own GUA ranges as private IPv6 addresses. Default: `false`. */ enablePrivateGua?: pulumi.Input<boolean>; /** * AWS account that is charged for active IP addresses managed in IPAM. Valid values are `ipam-owner` (default) and `resource-owner`. */ meteredAccount?: pulumi.Input<string>; /** * Determines which locales can be chosen when you create pools. Locale is the Region where you want to make an IPAM pool available for allocations. You can only create pools with locales that match the operating Regions of the IPAM. You can only create VPCs from a pool whose locale matches the VPC's Region. You specify a region using the regionName parameter. You **must** set your provider block region as an operating_region. */ operatingRegions?: pulumi.Input<pulumi.Input<inputs.ec2.VpcIpamOperatingRegion>[]>; /** * The ID of the IPAM's private scope. A scope is a top-level container in IPAM. Each scope represents an IP-independent network. Scopes enable you to represent networks where you have overlapping IP space. When you create an IPAM, IPAM automatically creates two scopes: public and private. The private scope is intended for private IP space. The public scope is intended for all internet-routable IP space. */ privateDefaultScopeId?: pulumi.Input<string>; /** * The ID of the IPAM's public scope. A scope is a top-level container in IPAM. Each scope represents an IP-independent network. Scopes enable you to represent networks where you have overlapping IP space. When you create an IPAM, IPAM automatically creates two scopes: public and private. The private scope is intended for private * IP space. The public scope is intended for all internet-routable IP space. */ publicDefaultScopeId?: pulumi.Input<string>; /** * 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 number of scopes in the IPAM. */ scopeCount?: pulumi.Input<number>; /** * A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. */ tagsAll?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * specifies the IPAM tier. Valid options include `free` and `advanced`. Default is `advanced`. */ tier?: pulumi.Input<string>; } /** * The set of arguments for constructing a VpcIpam resource. */ export interface VpcIpamArgs { /** * Enables you to quickly delete an IPAM, private scopes, pools in private scopes, and any allocations in the pools in private scopes. */ cascade?: pulumi.Input<boolean>; /** * A description for the IPAM. */ description?: pulumi.Input<string>; /** * Enable this option to use your own GUA ranges as private IPv6 addresses. Default: `false`. */ enablePrivateGua?: pulumi.Input<boolean>; /** * AWS account that is charged for active IP addresses managed in IPAM. Valid values are `ipam-owner` (default) and `resource-owner`. */ meteredAccount?: pulumi.Input<string>; /** * Determines which locales can be chosen when you create pools. Locale is the Region where you want to make an IPAM pool available for allocations. You can only create pools with locales that match the operating Regions of the IPAM. You can only create VPCs from a pool whose locale matches the VPC's Region. You specify a region using the regionName parameter. You **must** set your provider block region as an operating_region. */ operatingRegions: pulumi.Input<pulumi.Input<inputs.ec2.VpcIpamOperatingRegion>[]>; /** * 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>; /** * A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * specifies the IPAM tier. Valid options include `free` and `advanced`. Default is `advanced`. */ tier?: pulumi.Input<string>; }