UNPKG

@pulumi/gcp

Version:

A Pulumi package for creating and managing Google Cloud Platform resources.

163 lines (162 loc) 6.26 kB
import * as pulumi from "@pulumi/pulumi"; /** * A resource used to set the list of IP addresses to be used in a NAT service and manage the draining of destroyed IPs. * * > **Note:** This resource is to be used alongside a `gcp.compute.RouterNat` resource, * the router nat resource must have no defined `natIps` or `drainNatIps` parameters, * instead using the `initialNatIps` parameter to set at least one IP for the creation of the resource. * * To get more information about RouterNatAddress, see: * * * [API documentation](https://cloud.google.com/compute/docs/reference/rest/v1/routers) * * How-to Guides * * [Google Cloud Router](https://cloud.google.com/router/docs/) * * ## Example Usage * * ## Import * * RouterNatAddress can be imported using any of these accepted formats: * * * `projects/{{project}}/regions/{{region}}/routers/{{router}}/{{router_nat}}` * * * `{{project}}/{{region}}/{{router}}/{{router_nat}}` * * * `{{region}}/{{router}}/{{router_nat}}` * * * `{{router}}/{{router_nat}}` * * When using the `pulumi import` command, RouterNatAddress can be imported using one of the formats above. For example: * * ```sh * $ pulumi import gcp:compute/routerNatAddress:RouterNatAddress default projects/{{project}}/regions/{{region}}/routers/{{router}}/{{router_nat}} * ``` * * ```sh * $ pulumi import gcp:compute/routerNatAddress:RouterNatAddress default {{project}}/{{region}}/{{router}}/{{router_nat}} * ``` * * ```sh * $ pulumi import gcp:compute/routerNatAddress:RouterNatAddress default {{region}}/{{router}}/{{router_nat}} * ``` * * ```sh * $ pulumi import gcp:compute/routerNatAddress:RouterNatAddress default {{router}}/{{router_nat}} * ``` */ export declare class RouterNatAddress extends pulumi.CustomResource { /** * Get an existing RouterNatAddress 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?: RouterNatAddressState, opts?: pulumi.CustomResourceOptions): RouterNatAddress; /** * Returns true if the given object is an instance of RouterNatAddress. 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 RouterNatAddress; /** * A list of URLs of the IP resources to be drained. These IPs must be * valid static external IPs that have been assigned to the NAT. */ readonly drainNatIps: pulumi.Output<string[] | undefined>; /** * Self-links of NAT IPs to be used in a Nat service. Only valid if the referenced RouterNat * natIpAllocateOption is set to MANUAL_ONLY. */ readonly natIps: pulumi.Output<string[]>; /** * The ID of the project in which the resource belongs. * If it is not provided, the provider project is used. */ readonly project: pulumi.Output<string>; /** * Region where the NAT service reside. */ readonly region: pulumi.Output<string>; /** * The name of the Cloud Router in which the referenced NAT service is configured. */ readonly router: pulumi.Output<string>; /** * The name of the Nat service in which this address will be configured. */ readonly routerNat: pulumi.Output<string>; /** * Create a RouterNatAddress 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: RouterNatAddressArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering RouterNatAddress resources. */ export interface RouterNatAddressState { /** * A list of URLs of the IP resources to be drained. These IPs must be * valid static external IPs that have been assigned to the NAT. */ drainNatIps?: pulumi.Input<pulumi.Input<string>[]>; /** * Self-links of NAT IPs to be used in a Nat service. Only valid if the referenced RouterNat * natIpAllocateOption is set to MANUAL_ONLY. */ natIps?: pulumi.Input<pulumi.Input<string>[]>; /** * The ID of the project in which the resource belongs. * If it is not provided, the provider project is used. */ project?: pulumi.Input<string>; /** * Region where the NAT service reside. */ region?: pulumi.Input<string>; /** * The name of the Cloud Router in which the referenced NAT service is configured. */ router?: pulumi.Input<string>; /** * The name of the Nat service in which this address will be configured. */ routerNat?: pulumi.Input<string>; } /** * The set of arguments for constructing a RouterNatAddress resource. */ export interface RouterNatAddressArgs { /** * A list of URLs of the IP resources to be drained. These IPs must be * valid static external IPs that have been assigned to the NAT. */ drainNatIps?: pulumi.Input<pulumi.Input<string>[]>; /** * Self-links of NAT IPs to be used in a Nat service. Only valid if the referenced RouterNat * natIpAllocateOption is set to MANUAL_ONLY. */ natIps: pulumi.Input<pulumi.Input<string>[]>; /** * The ID of the project in which the resource belongs. * If it is not provided, the provider project is used. */ project?: pulumi.Input<string>; /** * Region where the NAT service reside. */ region?: pulumi.Input<string>; /** * The name of the Cloud Router in which the referenced NAT service is configured. */ router: pulumi.Input<string>; /** * The name of the Nat service in which this address will be configured. */ routerNat: pulumi.Input<string>; }