@pulumi/gcp
Version:
A Pulumi package for creating and managing Google Cloud Platform resources.
346 lines (345 loc) • 13.3 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* A deployment represents a zonal mirroring backend ready to accept
* GENEVE-encapsulated replica traffic, e.g. a zonal instance group fronted by
* an internal passthrough load balancer. Deployments are always part of a
* global deployment group which represents a global mirroring service.
*
* To get more information about MirroringDeployment, see:
*
* * [API documentation](https://cloud.google.com/network-security-integration/docs/reference/rest/v1/projects.locations.mirroringDeployments)
* * How-to Guides
* * [Mirroring deployment overview](https://cloud.google.com/network-security-integration/docs/out-of-band/deployments-overview)
*
* ## Example Usage
*
* ### Network Security Mirroring Deployment Basic
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
*
* const network = new gcp.compute.Network("network", {
* name: "example-network",
* autoCreateSubnetworks: false,
* });
* const subnetwork = new gcp.compute.Subnetwork("subnetwork", {
* name: "example-subnet",
* region: "us-central1",
* ipCidrRange: "10.1.0.0/16",
* network: network.name,
* });
* const healthCheck = new gcp.compute.RegionHealthCheck("health_check", {
* name: "example-hc",
* region: "us-central1",
* httpHealthCheck: {
* port: 80,
* },
* });
* const backendService = new gcp.compute.RegionBackendService("backend_service", {
* name: "example-bs",
* region: "us-central1",
* healthChecks: healthCheck.id,
* protocol: "UDP",
* loadBalancingScheme: "INTERNAL",
* });
* const forwardingRule = new gcp.compute.ForwardingRule("forwarding_rule", {
* name: "example-fwr",
* region: "us-central1",
* network: network.name,
* subnetwork: subnetwork.name,
* backendService: backendService.id,
* loadBalancingScheme: "INTERNAL",
* ports: ["6081"],
* ipProtocol: "UDP",
* isMirroringCollector: true,
* });
* const deploymentGroup = new gcp.networksecurity.MirroringDeploymentGroup("deployment_group", {
* mirroringDeploymentGroupId: "example-dg",
* location: "global",
* network: network.id,
* });
* const _default = new gcp.networksecurity.MirroringDeployment("default", {
* mirroringDeploymentId: "example-deployment",
* location: "us-central1-a",
* forwardingRule: forwardingRule.id,
* mirroringDeploymentGroup: deploymentGroup.id,
* description: "some description",
* labels: {
* foo: "bar",
* },
* });
* ```
*
* ## Import
*
* MirroringDeployment can be imported using any of these accepted formats:
*
* * `projects/{{project}}/locations/{{location}}/mirroringDeployments/{{mirroring_deployment_id}}`
*
* * `{{project}}/{{location}}/{{mirroring_deployment_id}}`
*
* * `{{location}}/{{mirroring_deployment_id}}`
*
* When using the `pulumi import` command, MirroringDeployment can be imported using one of the formats above. For example:
*
* ```sh
* $ pulumi import gcp:networksecurity/mirroringDeployment:MirroringDeployment default projects/{{project}}/locations/{{location}}/mirroringDeployments/{{mirroring_deployment_id}}
* ```
*
* ```sh
* $ pulumi import gcp:networksecurity/mirroringDeployment:MirroringDeployment default {{project}}/{{location}}/{{mirroring_deployment_id}}
* ```
*
* ```sh
* $ pulumi import gcp:networksecurity/mirroringDeployment:MirroringDeployment default {{location}}/{{mirroring_deployment_id}}
* ```
*/
export declare class MirroringDeployment extends pulumi.CustomResource {
/**
* Get an existing MirroringDeployment 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?: MirroringDeploymentState, opts?: pulumi.CustomResourceOptions): MirroringDeployment;
/**
* Returns true if the given object is an instance of MirroringDeployment. 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 MirroringDeployment;
/**
* The timestamp when the resource was created.
* See https://google.aip.dev/148#timestamps.
*/
readonly createTime: pulumi.Output<string>;
/**
* User-provided description of the deployment.
* Used as additional context for the deployment.
*/
readonly description: pulumi.Output<string | undefined>;
/**
* All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
*/
readonly effectiveLabels: pulumi.Output<{
[key: string]: string;
}>;
/**
* The regional forwarding rule that fronts the mirroring collectors, for
* example: `projects/123456789/regions/us-central1/forwardingRules/my-rule`.
* See https://google.aip.dev/124.
*/
readonly forwardingRule: pulumi.Output<string>;
/**
* Labels are key/value pairs that help to organize and filter resources.
* **Note**: This field is non-authoritative, and will only manage the labels present in your configuration.
* Please refer to the field `effectiveLabels` for all of the labels present on the resource.
*/
readonly labels: pulumi.Output<{
[key: string]: string;
} | undefined>;
/**
* The cloud location of the deployment, e.g. `us-central1-a` or `asia-south1-b`.
*/
readonly location: pulumi.Output<string>;
/**
* The deployment group that this deployment is a part of, for example:
* `projects/123456789/locations/global/mirroringDeploymentGroups/my-dg`.
* See https://google.aip.dev/124.
*/
readonly mirroringDeploymentGroup: pulumi.Output<string>;
/**
* The ID to use for the new deployment, which will become the final
* component of the deployment's resource name.
*/
readonly mirroringDeploymentId: pulumi.Output<string>;
/**
* The resource name of this deployment, for example:
* `projects/123456789/locations/us-central1-a/mirroringDeployments/my-dep`.
* See https://google.aip.dev/122 for more details.
*/
readonly name: 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>;
/**
* The combination of labels configured directly on the resource
* and default labels configured on the provider.
*/
readonly pulumiLabels: pulumi.Output<{
[key: string]: string;
}>;
/**
* The current state of the resource does not match the user's intended state,
* and the system is working to reconcile them. This part of the normal
* operation (e.g. linking a new association to the parent group).
* See https://google.aip.dev/128.
*/
readonly reconciling: pulumi.Output<boolean>;
/**
* The current state of the deployment.
* See https://google.aip.dev/216.
* Possible values:
* STATE_UNSPECIFIED
* ACTIVE
* CREATING
* DELETING
* OUT_OF_SYNC
* DELETE_FAILED
*/
readonly state: pulumi.Output<string>;
/**
* The timestamp when the resource was most recently updated.
* See https://google.aip.dev/148#timestamps.
*/
readonly updateTime: pulumi.Output<string>;
/**
* Create a MirroringDeployment 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: MirroringDeploymentArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering MirroringDeployment resources.
*/
export interface MirroringDeploymentState {
/**
* The timestamp when the resource was created.
* See https://google.aip.dev/148#timestamps.
*/
createTime?: pulumi.Input<string>;
/**
* User-provided description of the deployment.
* Used as additional context for the deployment.
*/
description?: pulumi.Input<string>;
/**
* All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
*/
effectiveLabels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* The regional forwarding rule that fronts the mirroring collectors, for
* example: `projects/123456789/regions/us-central1/forwardingRules/my-rule`.
* See https://google.aip.dev/124.
*/
forwardingRule?: pulumi.Input<string>;
/**
* Labels are key/value pairs that help to organize and filter resources.
* **Note**: This field is non-authoritative, and will only manage the labels present in your configuration.
* Please refer to the field `effectiveLabels` for all of the labels present on the resource.
*/
labels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* The cloud location of the deployment, e.g. `us-central1-a` or `asia-south1-b`.
*/
location?: pulumi.Input<string>;
/**
* The deployment group that this deployment is a part of, for example:
* `projects/123456789/locations/global/mirroringDeploymentGroups/my-dg`.
* See https://google.aip.dev/124.
*/
mirroringDeploymentGroup?: pulumi.Input<string>;
/**
* The ID to use for the new deployment, which will become the final
* component of the deployment's resource name.
*/
mirroringDeploymentId?: pulumi.Input<string>;
/**
* The resource name of this deployment, for example:
* `projects/123456789/locations/us-central1-a/mirroringDeployments/my-dep`.
* See https://google.aip.dev/122 for more details.
*/
name?: 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>;
/**
* The combination of labels configured directly on the resource
* and default labels configured on the provider.
*/
pulumiLabels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* The current state of the resource does not match the user's intended state,
* and the system is working to reconcile them. This part of the normal
* operation (e.g. linking a new association to the parent group).
* See https://google.aip.dev/128.
*/
reconciling?: pulumi.Input<boolean>;
/**
* The current state of the deployment.
* See https://google.aip.dev/216.
* Possible values:
* STATE_UNSPECIFIED
* ACTIVE
* CREATING
* DELETING
* OUT_OF_SYNC
* DELETE_FAILED
*/
state?: pulumi.Input<string>;
/**
* The timestamp when the resource was most recently updated.
* See https://google.aip.dev/148#timestamps.
*/
updateTime?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a MirroringDeployment resource.
*/
export interface MirroringDeploymentArgs {
/**
* User-provided description of the deployment.
* Used as additional context for the deployment.
*/
description?: pulumi.Input<string>;
/**
* The regional forwarding rule that fronts the mirroring collectors, for
* example: `projects/123456789/regions/us-central1/forwardingRules/my-rule`.
* See https://google.aip.dev/124.
*/
forwardingRule: pulumi.Input<string>;
/**
* Labels are key/value pairs that help to organize and filter resources.
* **Note**: This field is non-authoritative, and will only manage the labels present in your configuration.
* Please refer to the field `effectiveLabels` for all of the labels present on the resource.
*/
labels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* The cloud location of the deployment, e.g. `us-central1-a` or `asia-south1-b`.
*/
location: pulumi.Input<string>;
/**
* The deployment group that this deployment is a part of, for example:
* `projects/123456789/locations/global/mirroringDeploymentGroups/my-dg`.
* See https://google.aip.dev/124.
*/
mirroringDeploymentGroup: pulumi.Input<string>;
/**
* The ID to use for the new deployment, which will become the final
* component of the deployment's resource name.
*/
mirroringDeploymentId: 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>;
}