UNPKG

@pulumi/gcp

Version:

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

166 lines (165 loc) 6.45 kB
import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * 'DeploymentResourcePool can be shared by multiple deployed models, * whose underlying specification consists of dedicated resources.' * * To get more information about DeploymentResourcePool, see: * * * [API documentation](https://cloud.google.com/vertex-ai/docs/reference/rest/v1/projects.locations.deploymentResourcePools) * * ## Example Usage * * ### Vertex Ai Deployment Resource Pool * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as gcp from "@pulumi/gcp"; * * const deploymentResourcePool = new gcp.vertex.AiDeploymentResourcePool("deployment_resource_pool", { * region: "us-central1", * name: "example-deployment-resource-pool", * dedicatedResources: { * machineSpec: { * machineType: "n1-standard-4", * acceleratorType: "NVIDIA_TESLA_P4", * acceleratorCount: 1, * }, * minReplicaCount: 1, * maxReplicaCount: 2, * autoscalingMetricSpecs: [{ * metricName: "aiplatform.googleapis.com/prediction/online/accelerator/duty_cycle", * target: 60, * }], * }, * }); * ``` * * ## Import * * DeploymentResourcePool can be imported using any of these accepted formats: * * * `projects/{{project}}/locations/{{region}}/deploymentResourcePools/{{name}}` * * * `{{project}}/{{region}}/{{name}}` * * * `{{region}}/{{name}}` * * * `{{name}}` * * When using the `pulumi import` command, DeploymentResourcePool can be imported using one of the formats above. For example: * * ```sh * $ pulumi import gcp:vertex/aiDeploymentResourcePool:AiDeploymentResourcePool default projects/{{project}}/locations/{{region}}/deploymentResourcePools/{{name}} * ``` * * ```sh * $ pulumi import gcp:vertex/aiDeploymentResourcePool:AiDeploymentResourcePool default {{project}}/{{region}}/{{name}} * ``` * * ```sh * $ pulumi import gcp:vertex/aiDeploymentResourcePool:AiDeploymentResourcePool default {{region}}/{{name}} * ``` * * ```sh * $ pulumi import gcp:vertex/aiDeploymentResourcePool:AiDeploymentResourcePool default {{name}} * ``` */ export declare class AiDeploymentResourcePool extends pulumi.CustomResource { /** * Get an existing AiDeploymentResourcePool 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?: AiDeploymentResourcePoolState, opts?: pulumi.CustomResourceOptions): AiDeploymentResourcePool; /** * Returns true if the given object is an instance of AiDeploymentResourcePool. 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 AiDeploymentResourcePool; /** * A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. */ readonly createTime: pulumi.Output<string>; /** * The underlying dedicated resources that the deployment resource pool uses. * Structure is documented below. */ readonly dedicatedResources: pulumi.Output<outputs.vertex.AiDeploymentResourcePoolDedicatedResources | undefined>; /** * The resource name of deployment resource pool. The maximum length is 63 characters, and valid characters are `/^a-z?$/`. */ 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 region of deployment resource pool. eg us-central1 */ readonly region: pulumi.Output<string | undefined>; /** * Create a AiDeploymentResourcePool 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?: AiDeploymentResourcePoolArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering AiDeploymentResourcePool resources. */ export interface AiDeploymentResourcePoolState { /** * A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. */ createTime?: pulumi.Input<string>; /** * The underlying dedicated resources that the deployment resource pool uses. * Structure is documented below. */ dedicatedResources?: pulumi.Input<inputs.vertex.AiDeploymentResourcePoolDedicatedResources>; /** * The resource name of deployment resource pool. The maximum length is 63 characters, and valid characters are `/^a-z?$/`. */ 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 region of deployment resource pool. eg us-central1 */ region?: pulumi.Input<string>; } /** * The set of arguments for constructing a AiDeploymentResourcePool resource. */ export interface AiDeploymentResourcePoolArgs { /** * The underlying dedicated resources that the deployment resource pool uses. * Structure is documented below. */ dedicatedResources?: pulumi.Input<inputs.vertex.AiDeploymentResourcePoolDedicatedResources>; /** * The resource name of deployment resource pool. The maximum length is 63 characters, and valid characters are `/^a-z?$/`. */ 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 region of deployment resource pool. eg us-central1 */ region?: pulumi.Input<string>; }