import * as pulumi from "@pulumi/pulumi"; /** * A single instance of a developer workstation with its own persistent storage. * * > **Warning:** This resource is in beta, and should be used with the terraform-provider-google-beta provider. * See Provider Versions for more details on beta resources. * * To get more information about Workstation, see: * * * [API documentation](https://cloud.google.com/workstations/docs/reference/rest/v1beta/projects.locations.workstationClusters.workstationConfigs.workstations) * * How-to Guides * * [Workstations](https://cloud.google.com/workstations/docs/) * * ## Example Usage * * ### Workstation Basic * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as gcp from "@pulumi/gcp"; * * const _default = new gcp.compute.Network("default", { * name: "workstation-cluster", * autoCreateSubnetworks: false, * }); * const defaultSubnetwork = new gcp.compute.Subnetwork("default", { * name: "workstation-cluster", * ipCidrRange: "10.0.0.0/24", * region: "us-central1", * network: _default.name, * }); * const defaultWorkstationCluster = new gcp.workstations.WorkstationCluster("default", { * workstationClusterId: "workstation-cluster", * network: _default.id, * subnetwork: defaultSubnetwork.id, * location: "us-central1", * labels: { * label: "key", * }, * annotations: { * "label-one": "value-one", * }, * }); * const defaultWorkstationConfig = new gcp.workstations.WorkstationConfig("default", { * workstationConfigId: "workstation-config", * workstationClusterId: defaultWorkstationCluster.workstationClusterId, * location: "us-central1", * host: { * gceInstance: { * machineType: "e2-standard-4", * bootDiskSizeGb: 35, * disablePublicIpAddresses: true, * }, * }, * }); * const defaultWorkstation = new gcp.workstations.Workstation("default", { * workstationId: "work-station", * workstationConfigId: defaultWorkstationConfig.workstationConfigId, * workstationClusterId: defaultWorkstationCluster.workstationClusterId, * location: "us-central1", * labels: { * label: "key", * }, * env: { * name: "foo", * }, * annotations: { * "label-one": "value-one", * }, * }); * ``` * * ## Import * * Workstation can be imported using any of these accepted formats: * * * `projects/{{project}}/locations/{{location}}/workstationClusters/{{workstation_cluster_id}}/workstationConfigs/{{workstation_config_id}}/workstations/{{workstation_id}}` * * `{{project}}/{{location}}/{{workstation_cluster_id}}/{{workstation_config_id}}/{{workstation_id}}` * * `{{location}}/{{workstation_cluster_id}}/{{workstation_config_id}}/{{workstation_id}}` * * When using the `pulumi import` command, Workstation can be imported using one of the formats above. For example: * * ```sh * $ pulumi import gcp:workstations/workstation:Workstation default projects/{{project}}/locations/{{location}}/workstationClusters/{{workstation_cluster_id}}/workstationConfigs/{{workstation_config_id}}/workstations/{{workstation_id}} * $ pulumi import gcp:workstations/workstation:Workstation default {{project}}/{{location}}/{{workstation_cluster_id}}/{{workstation_config_id}}/{{workstation_id}} * $ pulumi import gcp:workstations/workstation:Workstation default {{location}}/{{workstation_cluster_id}}/{{workstation_config_id}}/{{workstation_id}} * ``` */ export declare class Workstation extends pulumi.CustomResource { /** * Get an existing Workstation 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, state?: WorkstationState, opts?: pulumi.CustomResourceOptions): Workstation; /** * Returns true if the given object is an instance of Workstation. 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 Workstation; /** * Client-specified annotations. This is distinct from labels. * **Note**: This field is non-authoritative, and will only manage the annotations present in your configuration. * Please refer to the field `effectiveAnnotations` for all of the annotations present on the resource. */ readonly annotations: pulumi.Output<{ [key: string]: string; } | undefined>; /** * Time when this resource was created. */ readonly createTime: pulumi.Output; /** * Human-readable name for this resource. */ readonly displayName: pulumi.Output; /** * All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services. */ readonly effectiveAnnotations: pulumi.Output<{ [key: string]: string; }>; /** * 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; }>; /** * 'Client-specified environment variables passed to the workstation container's entrypoint.' */ readonly env: pulumi.Output<{ [key: string]: string; } | undefined>; /** * Host to which clients can send HTTPS traffic that will be received by the workstation. * Authorized traffic will be received to the workstation as HTTP on port 80. * To send traffic to a different port, clients may prefix the host with the destination port in the format "{port}-{host}". */ readonly host: pulumi.Output; /** * Client-specified labels that are applied to the resource and that are also propagated to the underlying Compute Engine 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 location where the workstation parent resources reside. */ readonly location: pulumi.Output; /** * Full name of this resource. */ readonly name: pulumi.Output; /** * The ID of the project in which the resource belongs. * If it is not provided, the provider project is used. */ readonly project: pulumi.Output; /** * The combination of labels configured directly on the resource * and default labels configured on the provider. */ readonly pulumiLabels: pulumi.Output<{ [key: string]: string; }>; /** * Full resource name of the source workstation from which the workstation's persistent * directories will be cloned from during creation. */ readonly sourceWorkstation: pulumi.Output; /** * Current state of the workstation. */ readonly state: pulumi.Output; /** * A system-assigned unique identified for this resource. */ readonly uid: pulumi.Output; /** * The ID of the parent workstation cluster. */ readonly workstationClusterId: pulumi.Output; /** * The ID of the parent workstation cluster config. */ readonly workstationConfigId: pulumi.Output; /** * ID to use for the workstation. */ readonly workstationId: pulumi.Output; /** * Create a Workstation 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: WorkstationArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering Workstation resources. */ export interface WorkstationState { /** * Client-specified annotations. This is distinct from labels. * **Note**: This field is non-authoritative, and will only manage the annotations present in your configuration. * Please refer to the field `effectiveAnnotations` for all of the annotations present on the resource. */ annotations?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Time when this resource was created. */ createTime?: pulumi.Input; /** * Human-readable name for this resource. */ displayName?: pulumi.Input; /** * All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services. */ effectiveAnnotations?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * 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; }>; /** * 'Client-specified environment variables passed to the workstation container's entrypoint.' */ env?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Host to which clients can send HTTPS traffic that will be received by the workstation. * Authorized traffic will be received to the workstation as HTTP on port 80. * To send traffic to a different port, clients may prefix the host with the destination port in the format "{port}-{host}". */ host?: pulumi.Input; /** * Client-specified labels that are applied to the resource and that are also propagated to the underlying Compute Engine 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; }>; /** * The location where the workstation parent resources reside. */ location?: pulumi.Input; /** * Full name of this resource. */ name?: pulumi.Input; /** * The ID of the project in which the resource belongs. * If it is not provided, the provider project is used. */ project?: pulumi.Input; /** * The combination of labels configured directly on the resource * and default labels configured on the provider. */ pulumiLabels?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Full resource name of the source workstation from which the workstation's persistent * directories will be cloned from during creation. */ sourceWorkstation?: pulumi.Input; /** * Current state of the workstation. */ state?: pulumi.Input; /** * A system-assigned unique identified for this resource. */ uid?: pulumi.Input; /** * The ID of the parent workstation cluster. */ workstationClusterId?: pulumi.Input; /** * The ID of the parent workstation cluster config. */ workstationConfigId?: pulumi.Input; /** * ID to use for the workstation. */ workstationId?: pulumi.Input; } /** * The set of arguments for constructing a Workstation resource. */ export interface WorkstationArgs { /** * Client-specified annotations. This is distinct from labels. * **Note**: This field is non-authoritative, and will only manage the annotations present in your configuration. * Please refer to the field `effectiveAnnotations` for all of the annotations present on the resource. */ annotations?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Human-readable name for this resource. */ displayName?: pulumi.Input; /** * 'Client-specified environment variables passed to the workstation container's entrypoint.' */ env?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Client-specified labels that are applied to the resource and that are also propagated to the underlying Compute Engine 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; }>; /** * The location where the workstation parent resources reside. */ location: pulumi.Input; /** * The ID of the project in which the resource belongs. * If it is not provided, the provider project is used. */ project?: pulumi.Input; /** * Full resource name of the source workstation from which the workstation's persistent * directories will be cloned from during creation. */ sourceWorkstation?: pulumi.Input; /** * The ID of the parent workstation cluster. */ workstationClusterId: pulumi.Input; /** * The ID of the parent workstation cluster config. */ workstationConfigId: pulumi.Input; /** * ID to use for the workstation. */ workstationId: pulumi.Input; }