diff --git a/mmv1/products/workstations/WorkstationConfig.yaml b/mmv1/products/workstations/WorkstationConfig.yaml index 0fa00f89cfac..f871da5d0967 100644 --- a/mmv1/products/workstations/WorkstationConfig.yaml +++ b/mmv1/products/workstations/WorkstationConfig.yaml @@ -656,6 +656,11 @@ properties: description: | Disables support for plain TCP connections in the workstation. By default the service supports TCP connections via a websocket relay. Setting this option to true disables that relay, which prevents the usage of services that require plain tcp connections, such as ssh. When enabled, all communication must occur over https or wss. min_version: 'beta' + - name: 'maxUsableWorkstations' + type: Integer + description: | + Maximum number of workstations under this configuration a user can have workstations.workstation.use permission on. Only enforced on CreateWorkstation API calls on the user issuing the API request. + default_from_api: true - name: 'allowedPorts' type: Array default_from_api: true diff --git a/mmv1/templates/terraform/examples/workstation_config_basic.tf.tmpl b/mmv1/templates/terraform/examples/workstation_config_basic.tf.tmpl index 128aae10a59f..4b8f89b987d2 100644 --- a/mmv1/templates/terraform/examples/workstation_config_basic.tf.tmpl +++ b/mmv1/templates/terraform/examples/workstation_config_basic.tf.tmpl @@ -58,6 +58,8 @@ resource "google_workstations_workstation_config" "{{$.PrimaryResourceId}}" { "label" = "key" } + max_usable_workstations = 1 + host { gce_instance { machine_type = "e2-standard-4" diff --git a/mmv1/third_party/terraform/services/workstations/resource_workstations_workstation_config_test.go.tmpl b/mmv1/third_party/terraform/services/workstations/resource_workstations_workstation_config_test.go.tmpl index 2c53172487ba..ee56c4ee692c 100644 --- a/mmv1/third_party/terraform/services/workstations/resource_workstations_workstation_config_test.go.tmpl +++ b/mmv1/third_party/terraform/services/workstations/resource_workstations_workstation_config_test.go.tmpl @@ -811,6 +811,8 @@ resource "google_workstations_workstation_config" "default" { labels = { foo = "bar" } + + max_usable_workstations = 2 lifecycle { prevent_destroy = true